How to make your NFTs non-transferrable aka Soulbound
What is a Soulbound Token
Let’s first understand what a Soulbound Token (SBT) is:
A Soulbound Token is a type of digital asset or token that is unique and cannot be transferred to other individuals. This means that the owner of the token is the only one who has control over it and can use it for various purposes.
In simple words, a token that is non-transferrable is a Soulbound Token.
How to make your tokens Soulbound or Non-Transferrable
The easiest way to do this from the permissions tab on your thirdweb contract dashboard (Refer Guide).
If you prefer doing it via the Explorer, then you can follow the steps below to do so:
- Head to the thirdweb Dashboard and select your contract that you wish to make non-transferrable.
- Go to the “Explorer” tab on your contract dashboard.
- Under “write”, click on “revokeRole”.
- The “revokeRole” function expects two arguments to be provided, they are “Role” and “Account” respectively.
- The role that you would want to revoke is the “TRANSFER_ROLE”, and since the function expects the input for “Role” in bytes32 format, you would need to convert the string “TRANSFER_ROLE” into bytes32.
- Now the input you pass for “Role” would be
bytes32(”TRANSFER_ROLE), which is nothing but
- So the input you pass for “Role” would become
- Now since you want to remove transfer permissions for everyone i.e. every wallet address (which holds or will hold the NFT), the input you pass for “Account” would be
- Refer to the example screenshot below:
- You can now go to the “Permissions” tab on your dashboard and check that the changes you made would have been reflected.
TRANSFER_ROLE in bytes32 format would be
Refer to Tool if you want to see how the bytes32 conversion works)
Can’t get this working or need help? If you’ve followed the above and are still having issues, contact our support team for help.