CryptosBeginner
BlockchainLast reviewed 27 August 2026

Smart contract

A smart contract is blockchain-deployed code that executes according to predefined rules when called.

Quick answer

A smart contract is blockchain-deployed code that executes according to predefined rules when called.

What is Smart contract?

A smart contract is a program whose state and execution are handled by a blockchain or compatible execution environment. It can hold assets, enforce conditions, and interact with other contracts, but it cannot guarantee that its code matches a human promise.

The useful way to approach this term is to separate its definition from the assumptions people often attach to it. In crypto, the same word can appear in a protocol rule, a user interface, a market-data label, or a marketing claim. Check which layer the explanation is describing.

Why does smart contract matter?

Smart contracts introduce programmable finance but also create risks involving bugs, permissions, oracle inputs, upgrade keys, and irreversible calls. Reading a contract’s authority model matters as much as reading its marketing.

Concrete example

See it in a real situation

A swap contract can accept one token, calculate an exchange according to its rules, and send another token back, with the transaction recorded on-chain.

Common misconceptions

What this term does not mean

  • A smart contract is not necessarily smart, legally binding, or free from bugs.
  • Code running on-chain cannot independently know off-chain prices unless an oracle or signed data source supplies them.

Related terms

Sources and further reading

Definitions are written for education and checked against the sources below where relevant. A source can explain a protocol or rule without endorsing every product built around it.