thirdweb: Create a Gated Website Using NFTs and IPFS
Learn how to create a gated website using NFTs and IPFS.
What is thirdweb?
1. Start by navigating to the thirdweb dashboard and connecting your Cryptowallet.

2. Select ‘Deploy New Contract'.

3. Under 'Popular', select ‘Edition Drop’:


4. Give your NFT collection a name, icon, and description, then confirm that the recipient address is your crypto wallet address.

5. Select ‘Deploy Now’ and confirm the transaction through your crypto wallet.

6. Next, we need to create an IPFS bucket on Filebase.
7. Select ‘Buckets’ from the left sidebar menu, or navigate to.

8. Enter a bucket name and choose the IPFS storage network to create the bucket.

9. Now, upload your NFTs to Filebase using the web console and selecting ‘Folder’, then select the folder that contains your NFT files.
10. You will see your folder uploaded as a single object:

11. Copy the CID of your folder:

12. Navigate to your IPFS Folder using the Filebase IPFS gateway to see your folder’s files:
13. Head back to the thirdweb dashboard, where you will see the page for your NFT collection.

14. Open a command line window and install the thirdweb SDK:
15. Open an IDE such as VSCode and insert the following code, replacing CONTRACT with your contract address, WALLET_ADDRESS with your crypto wallet address, each IPFS_CID with your IPFS folder CID you took note of earlier and replacing the name and description of each NFT with your desired information.
CONTRACT with your contract address, WALLET_ADDRESS with your crypto wallet address, each IPFS_CID with your IPFS folder CID you took note of earlier and replacing the name and description of each NFT with your desired information.16. Save this script as mint.js, then run this script with the command:
17. Refresh your thirdweb dashboard. Your NFT(s) will be listed.

18. Select ‘Settings’, then select ‘Add Initial Claim Phase’ to configure your drop’s claim phases.

19. Configure your claim phase with your desired parameters, then select ‘Save Claim Phases’.

20. Copy your NFT Edition Drop’s contract address and save it to be used later in the tutorial.

21. Next, we’ll use a template repository to create a gated website that uses our NFT Edition Drop.
22. Install the project’s dependencies.
23. Start the app.
24. Open the src/App.js file.
src/App.js file.25. By default, the app will be running at 127.0.0.1, and will look like this:
127.0.0.1, and will look like this:
26. Select ‘Connect MetaMask’ to connect your cryptowallet to the website.

27. Select ‘Mint NFT’ to claim your NFT membership drop. Authorize the transaction through your cryptowallet.

28. You should see the confirmation message indicating the successful mint of your drop NFT.

Previousthirdweb: Create a Discord Bot That Gives Roles to NFT HoldersNextthirdweb: Create an NFT Marketplace with thirdweb and IPFS
Last updated