TRON Smart Contract Deployment Cost: Energy, Bandwidth and TRX
Five real TRON contract deployments from Nov 19-20, 2026: energy per byte of code, bandwidth, TRX burned, a free estimate, and burning vs renting energy.
- Category
- Calculations
- Published
- Reading time
- 8 min

Deploying a smart contract on TRON costs energy for running the constructor plus 200 energy for every byte of code the network stores, and bandwidth equal to the size of the transaction. Five mainnet deployments on Nov 19-20, 2026 used between 941,187 and 2,560,528 energy and between 6,872 and 14,657 bandwidth. Burned in full at the rates of Nov 20, 2026 (100 SUN per unit of energy, 1,000 SUN per byte of bandwidth), that is about 101 to 271 TRX.
Below: the receipts, the java-tron code behind them, a free estimate, and why the energy has to be on the address in full before you broadcast.
Five deployments from Nov 19-20, 2026
We read CreateSmartContract transactions block by block through the TronGrid API. Deployments come in bursts: the 100 blocks between about 08:29 and 08:34 UTC on Nov 19 held seven. The table takes five of different sizes plus one that failed.
| Contract (deploy transaction) | Code in the transaction, bytes | Code stored, bytes | Energy | Bandwidth | TRX actually burned |
|---|---|---|---|---|---|
| TronTreasury (2a897f5c…) | 6,569 | 5,904 | 1,252,347 | 6,872 | 132.1067 |
| TronDepositFactory (8cf3cdbc…) | 8,770 | 5,094 | 1,713,887 | 9,079 | 180.4677 |
| TPq66c…sqewc5 (b04fea2a…) | 5,948 | 3,896 | 1,047,007 | 7,905 | 0 |
| TLjTjz…VzAGFuht (cfea5561…) | 5,640 | 4,046 | 941,187 | 7,088 | 41.8901 |
| LukkeyTronRotatableFactory (a6026ae5…) | 14,338 | 2,249 | 2,560,528 | 14,657 | 14.657 |
| Failed, no contract (cc415dac…) | 5,640 | 0 | 874 | 7,088 | 7.1733 |
Names are those the deployers set. “Code stored” is the length of contractResult in the receipt, equal to runtimecode from getcontractinfo. TRX burned depends on what each address already had: the third was fully covered, the fifth burned for bandwidth only. No receipt has an energy_penalty_total: a new contract has no dynamic surcharge, unlike USDT (how dynamic energy works).
What the cost depends on
Energy: 200 per stored byte, plus the constructor
In java-tron, VMActuator charges the deployment after the constructor has run: it takes the returned code and multiplies its length by EnergyCost.getCreateData(), which is the constant CREATE_DATA = 200 in EnergyCost.java. So:
deployment energy = 200 × bytes of code stored + energy of the constructor
| Deployment | 200 × stored bytes | Share of total energy |
|---|---|---|
| TronTreasury | 1,180,800 | 94% |
| TLjTjz…VzAGFuht | 809,200 | 86% |
| TPq66c…sqewc5 | 779,200 | 74% |
| TronDepositFactory | 1,018,800 | 59% |
| LukkeyTronRotatableFactory | 449,800 | 18% |
For a plain contract the stored code is most of the bill. The two factories differ: each receipt lists two internal create calls, so the constructor deployed two more contracts and paid for them too. That is why the Lukkey transaction carried 14,338 bytes of code but stored only 2,249.
Bandwidth: the size of the whole transaction
Bandwidth is the serialized transaction plus 64 bytes that java-tron reserves for the result of every contract transaction (BandwidthProcessor.java). In all five receipts, bandwidth was exactly the size of raw_data plus 134 bytes: the 64 reserved, a 65-byte signature and 5 bytes of framing. The ABI travels in the transaction too.
For any transaction, bandwidth is taken all or nothing. The code checks whether the address’s staked or delegated bandwidth covers the full size, then whether the 600 free daily units do; if neither does, it burns TRX for every byte at 1,000 SUN. A 6,872-byte deployment therefore cannot use the free allowance at all. More on the unit price in TRON bandwidth cost.
Estimating a deployment for free
The TRON reference says triggerconstantcontract can estimate the energy of a contract deployment. We tested it on Nov 20, 2026 around 05:55 UTC: we sent the TronTreasury bytecode from the transaction above as data, without contract_address, from the address that had deployed it. TronGrid returned energy_used 1,252,347, exactly the receipt, and a constant_result of 5,904 bytes, exactly the stored code. Nothing was signed or broadcast.
Illustrative example, check the exact format in the triggerconstantcontract reference:
curl -s https://api.trongrid.io/wallet/triggerconstantcontract \
-H 'content-type: application/json' \
-d '{
"owner_address": "<the address that will deploy>",
"data": "<full deployment bytecode with constructor arguments, hex>",
"visible": true
}'
Read energy_used for energy. For bandwidth, take the byte size of raw_data and add 134 for one signature, as in the receipts. The estimate holds if the constructor does not depend on state that changes before you deploy; the general caveats are in estimating energy with triggerconstantcontract.

Burning or renting energy for a deployment
Take the TronTreasury figure, 1,252,347 energy, as a model calculation:
| Way to pay the energy | TRX |
|---|---|
| Burn at 100 SUN per unit | 125.23 |
| Rent at 34 SUN per unit for 1 hour | 42.58 |
| Kept by renting instead of burning | 82.65 |
| Rent with a 5% margin, 1,315,000 energy | 44.71 |
Bandwidth is extra: 6,872 bytes burn 6.872 TRX unless the address has that much staked or delegated bandwidth.
Staking for a one-off makes little sense: at 9.65 energy per staked TRX a day as of Nov 20, 2026, that is about 129,700 TRX locked (freeze TRX or rent energy).
Rental figures use the current rate on Nov 22, 2026. The rate changes; the exact price is shown in the service before you pay, and reference prices are on the pricing page. If you order a deployment volume through the energy API, check it against minVolume and maxVolume from the quote method listed in the API documentation before you rely on one order.
Why the full amount has to be on the address first
Before the constructor runs, java-tron fixes the energy limit for the whole deployment (getAccountEnergyLimitWithFixRatio in VMActuator.java):
energy limit = min(energy on the address + TRX balance / 100 SUN, fee_limit / 100 SUN)
Three things follow, and the receipts show each.
- A shortfall is burned, not the whole bill. The TLjTjz deployment used 593,166 units from the address and burned 34.8021 TRX for the other 348,021. Renting too little costs the gap at the burn price.
- If the limit is too low, everything inside it is lost. The code is stored last, so a deployment can run its whole constructor and then fail at the 200-per-byte step. On any such exception the VM spends the entire limit. The failed deployment above came 3 seconds after a successful one of the same size from the same address; this time the address had 21 units of energy and TRX for 853 more, so the limit was 874. The receipt says OUT_OF_ENERGY, 7.1733 TRX is gone, and no contract exists. More cases are in the out-of-energy guide.
- fee_limit caps rented energy too. The limit includes staked and delegated energy, so a deployment of 1,252,347 energy needs
fee_limitof at least 125.2347 TRX even if every unit is rented. The network maximum is 15,000 TRX as of Nov 20, 2026, enough for 150,000,000 energy. Our five deployers set 268.86 to 1,000 TRX; Lukkey’s 268,855,440 SUN is exactly 105% of its energy at 100 SUN, which looks like an estimate plus a 5% margin.
The limit is fixed before execution, so the rented amount has to arrive before you broadcast; unused rented energy stays until the term ends (how long rented energy lasts).
consume_user_resource_percent and origin_energy_limit
These two fields are set in the deployment and decide how later calls split energy between you and your users, as explained in TRON energy for dApps and bots. They do not change the deployment cost: four of our five deployments set 100 and 10,000,000, the fifth 50 and 10,000,000.

Deploying with rented energy, step by step
- Simulate the deployment with
triggerconstantcontractfrom the deploying address; stop iftransaction.retshows FAILED. - Size the bandwidth:
raw_databytes plus 134, burned in full at 1,000 SUN unless staked or delegated bandwidth covers all of it. - Order energy for the estimate plus a margin, and wait until it shows on the address.
- Set fee_limit above the full estimate × 100 SUN, rented energy included.
- Deploy within the rental term, with TRX for bandwidth, and compare
energy_usage_totalandenergy_feein the receipt with the estimate.
FAQ
How much TRX does it cost to deploy a contract on TRON? In our five deployments, 101 to 271 TRX if everything is burned, as of Nov 20, 2026. Most of it is energy: 200 per stored byte plus the constructor.
Can I deploy with only part of the energy rented?
Yes, the network burns TRX for the rest, as long as the balance and fee_limit cover it. If they do not, the deployment fails and the whole limit is spent.
Does a long ABI or contract name raise the energy? No. They make the transaction bigger, so they add bandwidth only. More answers are in the FAQ.