Deploying
Deploy a compiled TRON smart contract using TronIDE, TronBox, or TronWeb. This page covers the high-level deployment paths.
Prerequisites
This page covers the high-level deployment paths for TRON smart contracts. Pick the path that matches your workflow:
- TronIDE — browser-based, shown below. Good for occasional deploys and learning.
- TronBox CLI — see Quickstart for the full walkthrough. Good for project-based and CI/CD workflows.
- HTTP API directly — see Smart contract deployment and invocation. Good for custom deployment pipelines or low-level control.
Preparation
Before deploying, ensure the following:
- TronLink wallet — install the TronLink browser extension and import or create the deployer account.
- Network selection — in TronLink, select the correct network (Mainnet, Shasta testnet, or Nile testnet). This guide uses Shasta for demonstration.
- TRX balance — the deployer account needs TRX for
fee_limitand the deployment Energy cost. For Shasta, claim testnet TRX from the Shasta faucet.
Deploy in TronIDE
After compiling your contract (see Writing & compiling), open the DEPLOY & RUN TRANSACTIONS tab and set:
| Field | Value |
|---|---|
| ENVIRONMENT | Injected TronWeb (uses the connected TronLink account) |
| ACCOUNT | the wallet address to deploy from |
| CONTRACT | the main contract to deploy |
| Fee Limit | maximum TRX to spend on this deployment, in sun (typically 1,000 TRX = 1000 * 1e6 for a TRC-20 deploy) |
| TRX amount to send | only set if your constructor is payable and you want to fund the contract; otherwise 0 |
Once the parameters are set, click Deploy. TronLink will prompt you to sign the transaction.
Confirming a successful deployment
After signing, the transaction is broadcast. To confirm the deployment landed on-chain, query the transaction info by ID:
BASE_URL=https://api.shasta.trongrid.io # example — replace with any TRON node (TronGrid, third-party, or self-hosted)
curl -X POST ${BASE_URL}/walletsolidity/gettransactioninfobyid \
-d '{"value":"17532357496d30002a9344afa53be0c53187d2c2f531a96c8a4c5e73e0647521"}'A successful deployment returns a result with contractResult populated and the contract address in the contract_address field. For the full confirmation flow, see Transaction lifecycle.
Common deployment failuresIf
resultreturnsOUT_OF_ENERGY, increasefee_limitand try again. If you seeBAD_JUMP_DESTINATION, your bytecode may be malformed — recompile and redeploy. For other failure modes, see Smart contract errors.
After deployment
Once the contract is deployed, you can:
- Verify the source on TRONSCAN so users can audit it — see Contract verification.
- Call methods on the deployed contract from your DApp or scripts — see Interacting with contracts.
- Issue a TRC-20 token on top of your deployment — see Issuing a TRC-20 token.
Related resources
- Quickstart — TronBox CLI deployment walkthrough
- Smart contract deployment and invocation — HTTP API path
- Contract verification — verify source on TRONSCAN
- Interacting with contracts — call methods on the deployed contract
- FeeLimit & Energy cost — cost management guide
Updated 7 days ago