Overview
Once you've tested locally with resim, the next step is deploying to the public Stokenet testnet. The process is the same for Mainnet — the only difference is you use real XRD.
Stokenet vs Mainnet
Always deploy and test on Stokenet first. Stokenet XRD is free and has no value. Never send Mainnet XRD to Stokenet addresses.
1. Get Test XRD
Open the Radix Wallet and switch to the Stokenet network. Use the built-in faucet to request free test XRD — you'll need it to pay transaction fees for deployment.
2. Build Your Package
scrypto buildYour compiled WASM file is at:
target/wasm32-unknown-unknown/release/<package_name>.wasmThe build also generates an RPD (Radix Package Definition) file at the same location, which describes your blueprints and their interfaces.
3. Deploy via Developer Console
- Go to stokenet-console.radixdlt.com/deploy-package
- Click "Connect" in the top-right and connect your Radix Wallet
- Upload your
.wasmand.rpdfiles - Review the auto-generated transaction manifest
- Click "Send to Wallet" and approve the transaction in your wallet
Once confirmed, the console displays your package address. Save it — you'll need it to instantiate components.
4. Instantiate a Component
Go to the "Send Raw Transaction" section of the console and submit a manifest that calls your instantiation function:
CALL_FUNCTION
Address("<PACKAGE_ADDRESS>")
"GumballMachine"
"instantiate"
Decimal("5")
;
CALL_METHOD
Address("<YOUR_ACCOUNT>")
"deposit_batch"
Expression("ENTIRE_WORKTOP")
;The resulting component address is your live dApp on Stokenet.
Deploying to Mainnet
The process is identical — use console.radixdlt.com instead and ensure your wallet is on Mainnet with real XRD for fees.
Royalties
Before deploying to Mainnet, consider setting package royalties to earn XRD whenever others use your blueprints.
Next Steps
- Scrypto Fundamentals — understand the asset-oriented programming model
- Radix dApp Toolkit — build a frontend that connects to your component
- Transaction Manifest Language — learn to write manifests directly
