TLDR:
- Learn to create a custom SPL token on Solana's devnet
- Deploy an audited vesting program (Bonfida)
- Set up a vesting schedule and release tokens
- Works for both devnet and mainnet (adjust endpoint and SOL balance)
Introduction to Solana Token Vesting
This guide provides a step-by-step walkthrough for creating tokens and implementing vesting schedules on the Solana blockchain. Whether you're a project founder or developer, understanding token vesting is crucial for proper tokenomics implementation.
Key Concepts Covered:
- SPL token creation
- Token account derivation
- Vesting program deployment
- Vesting schedule configuration
- Token release mechanics
Prerequisites
Before beginning, ensure you have:
- Rust programming language installed
- Solana CLI tools configured
- SPL token CLI utility
- Basic understanding of Solana's account model
๐ Get started with Solana development
Complete Workflow
1. Infrastructure Setup
- Configure Solana CLI to use your Chainstack node endpoint
- Generate two keypair wallets (token creator and recipient)
- Fund both wallets with devnet SOL via faucet
2. Token Creation
spl-token create-token --url YOUR_CHAINSTACK_ENDPOINT3. Token Account Derivation
spl-token create-account TOKEN_ADDRESS4. Token Minting
spl-token mint TOKEN_ADDRESS 10005. Vesting Program Deployment
- Clone Bonfida's token vesting program
- Build the program with Cargo
- Deploy to devnet
6. Vesting Instance Creation
./cli create-vesting \
--program PROGRAM_ADDRESS \
--seed UNIQUE_SEED \
--token TOKEN_ADDRESS \
--amount AMOUNT \
--time UNIX_TIMESTAMP7. Token Release
./cli release --program PROGRAM_ADDRESS --seed UNIQUE_SEEDDetailed Steps
Setting Up Solana CLI With Chainstack Node
solana config set --url YOUR_CHAINSTACK_ENDPOINTVerify your configuration:
solana config getWallet Generation and Funding
Create password-protected JSON keypairs:
solana-keygen new --outfile ~/wallet/keypair.jsonFund via devnet faucet:
solana airdrop 1 WALLET_ADDRESS --url YOUR_CHAINSTACK_ENDPOINTToken Economics Considerations
When creating your vesting schedule, consider:
- Total token supply
- Vesting period duration
- Cliff periods
- Release frequency
- Team allocation percentages
๐ Advanced tokenomics strategies
Best Practices
- Always test vesting schedules on devnet first
- Consider using multisig for important token accounts
- Document your vesting schedule clearly for transparency
- Regularly audit token distributions
FAQ Section
Q: Can I use this same process on Solana mainnet?
A: Yes, simply change the endpoint and ensure you have sufficient SOL for transactions.
Q: How do I calculate token amounts for vesting?
A: Remember Solana uses 9 decimals by default. 1 full token = 1,000,000,000 base units.
Q: Can multiple people release vested tokens?
A: Yes, any wallet can pay the gas fee to release tokens that have vested.
Q: Is the Bonfida vesting program secure?
A: Yes, it's been audited and used by multiple projects in production.
Q: How do I verify my token creation was successful?
A: Check the transaction on a Solana explorer using your Chainstack endpoint.
Conclusion
Implementing proper token vesting is essential for any serious Solana project. This guide has walked you through the complete process from token creation to vesting schedule implementation. Remember that while we used devnet for testing, the same principles apply to mainnet deployment. Always conduct thorough testing and consider security best practices when managing token allocations.
For more advanced Solana development techniques:
๐ Explore Solana development resources