Deploy Native Token Transfers on Solana#
Native Token Transfers (NTT) enable seamless multichain transfers of SPL tokens on Solana using Wormhole's messaging protocol. Instead of creating wrapped tokens, NTT allows native assets to move across chains while maintaining their original properties.
This guide walks you through deploying NTT on Solana, including setting up dependencies, configuring token compatibility, and using the NTT CLI to deploy in hub-and-spoke or burn-and-mint mode.
By the end, a fully deployed NTT will be set up, allowing your token to transfer between Solana and other supported chains.
Prerequisites#
Before deploying NTT on Solana, ensure you have the following:
Use the Solana and Anchor versions listed above to avoid compatibility issues while following this guide.
Overview of the Deployment Process#
Deploying NTT with the CLI on Solana follows a structured process:
-
Choose your token setup:
- Use an existing SPL token - if your token is already deployed on Solana, you can skip token creation and move directly to the Set Up NTT section
-
Create a new SPL token - if you don't already have an SPL token deployed, you'll need to deploy and configure it on Solana before integrating with Wormhole's NTT
Create and Mint SPL Tokens
This section walks you through generating a Solana wallet, deploying an SPL token, creating a token account, and minting tokens.
-
Generate a Solana key pair - run the following command to create a new wallet:
-
Set Solana configuration - configure the Solana CLI to use the generated key pair using the following command:
-
Select an RPC URL - configure Solana to use the appropriate network using one of the following commands:
-
Fund your wallet - ensure you have enough SOL to create a token. If deploying on devnet, request an airdrop with the following commands:
-
Install SPL Token CLI - install or update the required CLI tool
-
Create a new SPL token - initialize the token on Solana
-
Create a token account - generate an account to hold the token
-
Mint tokens - send 1000 tokens to the created account
Note
NTT versions
>=v2.0.0+solana
support SPL tokens with transfer hooks. -
-
Choose your deployment model:
- Hub-and-spoke - tokens are locked on a hub chain and minted on destination spoke chains. Since the token supply remains controlled by the hub chain, no changes to the minting authority are required
- Burn-and-mint - tokens are burned on the source chain and minted on the destination chain. This requires transferring the SPL token's minting authority to the Program Derived Address (PDA) controlled by the NTT program
-
Deploy and configure NTT - use the NTT CLI to initialize and deploy the NTT program, specifying your SPL token and deployment mode
Following this process, your token will fully integrate with NTT, enabling seamless transfers between Solana and other chains.
By default, NTT transfers to Solana require manual relaying, meaning users must complete a transaction on Solana to finalize the transfer. For automatic relaying, where transactions are completed without user intervention, additional setup is required. Contact Wormhole contributors to enable automatic relaying support for your deployment.
Set Up NTT#
To integrate your token with NTT on Solana, you must initialize the deployment and configure its parameters. This process sets up the required contracts and may generate key pairs if they don't exist. These key pairs are used to sign transactions and authorize actions within the NTT deployment.
The NTT CLI manages deployments, configures settings, and interacts with the NTT system. Follow these steps to set up NTT using the CLI tool:
-
Create a new NTT project - set up a deployment workspace
-
Initialize the deployment - generate a
deployment.json
file with your deployment settings
Note
Testnet deployment settings work for both Solana Testnet and Devnet networks.
Set Mint Authority#
If you use burn-and-mint mode, follow these steps to enable the NTT program to mint tokens on Solana. This involves deriving the PDA as the token authority and updating the SPL token's minting permissions.
If you want to use hub-and-spoke, skip this section and proceed to Deploy and Configure NTT.
Before updating the mint authority, you must create metadata for your SPL token. You can visit this repository to see an example of how to create metadata for your SPL token.
Follow these steps to set the mint authority using the NTT CLI:
-
Generate an NTT program key pair - create a unique key pair for the NTT program. The key pair must start with "ntt" to identify it as belonging to the NTT deployment
-
Derive the token authority - generate the PDA, which will manage token minting
-
Set SPL token mint authority - delegate minting control to the derived PDA
Deploy and Configure NTT#
After setting up your deployment, finalize the configuration and deploy the NTT program on Solana by following these steps:
-
Deploy NTT to Solana - run the appropriate command based on your deployment mode:
Tip
The
add-chain
command accepts an optional--solana-priority-fee
flag, which sets the priority fee in microlamports. The default is50000
. -
Verify deployment status - after deployment, check if your
deployment.json
file matches the on-chain configuration using the following command:If needed, sync your local configuration with the on-chain state:
-
Configure inbound and outbound rate limits - by default, the inbound and outbound limits are set to
0
and must be updated before deployment. For EVM chains, values must be set using 18 decimals, while Solana uses nine decimals.Open your
deployment.json
file and adjust the values based on your use case: -
Push the final deployment - once rate limits are set, push the deployment to Solana using the specified key pair to cover gas fees
Troubleshoot Deployment Issues#
If your deployment fails, it may be due to leftover program buffer accounts taking up storage on Solana. These temporary accounts are created during deployment but may persist if interrupted. Refer to the Solana program deployment guide for instructions on finding and closing these buffer accounts to free up space and allow redeployment.
Where to Go Next#
-
Deploy NTT on EVM Chains
After deploying NTT on Solana, deploy and integrate it on EVM chains to enable seamless multichain transfers.
-
Test Your Deployment
Follow the NTT Post Deployment Guide for integration examples and testing instructions.
-
Add NTT to Your dApp
Configure Wormhole Connect, a plug-and-play bridging UI, to enable multichain transfers for your token.