Configure Reown (WalletConnect) integration for web3 wallet connections
Bicrypto uses Reown (formerly WalletConnect) to enable users to connect their web3 wallets to the platform. This integration allows users to interact with blockchain features using popular wallets like MetaMask, Coinbase Wallet, Trust Wallet, and more.
Go to https://cloud.reown.com and sign up for a free account.
After logging in, click on "Create New Project" or "New Project" button.
Fill in your project details:
After creating your project, you'll see a Project ID on your project dashboard. This is a unique identifier that looks like:
b56e18d47c72ab683b10814fe9495694
Copy this Project ID - you'll need it for the next step.
Navigate to your project's root directory and open the .env file.
Add the following line to your .env file, replacing the value with your actual Project ID:
NEXT_PUBLIC_WALLET_CONNECT_PROJECT_ID="your_project_id_here"
Example:
NEXT_PUBLIC_WALLET_CONNECT_PROJECT_ID="b56e18d47c72ab683b10814fe9495694"
Save the .env file and close it.
For the changes to take effect, restart your frontend application:
pnpm updator:frontend
This will rebuild and restart the frontend with the new WalletConnect configuration.
By default, Bicrypto supports the following networks for wallet connections:
Main Ethereum network
Layer 2 scaling solution
Optimistic rollup network
Layer 2 optimistic rollup
Note: Network configurations are defined in frontend/config/wallet.ts. You can customize the supported networks by modifying this file.
Navigate to any page with wallet connection functionality (e.g., ICO investment page)
Click on "Connect Wallet" button
The Reown modal should appear showing available wallet options
Connect your wallet and verify the connection is successful
Check the following:
NEXT_PUBLIC_WALLET_CONNECT_PROJECT_ID is correctly set in .envIf you see a fallback Project ID being used:
NEXT_PUBLIC_WALLET_CONNECT_PROJECT_ID.env file is in the root directory of the projectIf users can't connect to specific networks:
frontend/config/wallet.tsYou've successfully configured Reown (WalletConnect) for your Bicrypto platform. Users can now connect their web3 wallets to interact with blockchain features. Make sure to test the connection thoroughly and monitor your Reown dashboard for usage statistics and potential issues.