A transaction is composed of one or more Actions, and each action costs a deterministic amount of gas units. These gas units are translated into a cost in NEAR tokens, which the user must pay for the transaction to be processed.
Transaction Lifecycle
Transactions in NEAR go through several stages from creation to finality:Learn More
Explore the detailed anatomy of a transaction
Transaction Components
Each transaction contains:- Required Fields
- Validation Fields
- Signer: The account that signs the transaction
- Receiver: The account on which to perform the actions
- Actions: The set of actions to be performed
Transaction Status
As transactions are processed, they receive a status:- Success: All actions executed successfully
- Failed: An action failed and was rolled back
- Unknown: Receipt is not known by the network
A transaction is considered final when all its receipts are processed. This typically takes 1-3 seconds.
Gas and Fees
Every transaction requires gas to be processed:- Gas is calculated in deterministic gas units
- Gas units are converted to NEAR tokens using the network’s gas price
- Users pay the fee upfront when the transaction is submitted
- Unused gas is refunded (minus a small refund fee)
Learn More
Understand how gas works in NEAR