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.
  • Resources and TRX balance — the deployer needs enough Energy, or enough TRX to pay for an Energy shortfall, and enough Bandwidth or TRX for the deployment transaction. For Shasta, claim testnet TRX from the Shasta faucet.
TronLink wallet network selector showing Shasta testnet selected

Deploy in TronIDE

After compiling your contract (see Writing & compiling), open the DEPLOY & RUN TRANSACTIONS tab and set:

FieldValue
ENVIRONMENTInjected TronWeb (uses the connected TronLink account)
ACCOUNTthe wallet address to deploy from
CONTRACTthe main contract to deploy
Fee Limitcaller-side Energy budget cap for this deployment, in sun; it includes the deployer's available Energy at its current price and any Energy paid for by burning TRX, but excludes Bandwidth and other transaction fees (a common starting value for a TRC-20 deployment is 1,000 TRX = 1000 * 1e6)
TRX amount to sendonly 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.

TronIDE Deploy & Run Transactions tab with Environment, Account, Contract fields

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"}'

Treat the deployment as successful only after the solidified receipt is available, the top-level result is not FAILED, and receipt.result is SUCCESS. Then read contract_address and use GetContract to confirm that contract bytecode is available at that address. The presence of contractResult or contract_address alone does not prove that the constructor completed successfully. For the full confirmation flow, see Transaction lifecycle.

📘

Common deployment failures

If result returns OUT_OF_ENERGY, increase fee_limit and try again. If you see BAD_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:


Related resources