Smart Contract
A smart contract is on-chain code that executes automatically when called. Learn how contracts hold state, why bugs are permanent and what they power.
A smart contract is a program deployed to a blockchain that runs exactly as written whenever a transaction calls one of its functions, with no intermediary holding the funds or enforcing the terms. On Ethereum and compatible networks a contract has its own address, its own storage and its own balance, and every node re-executes the same code to reach the same result. Because both the bytecode and the resulting state are public and replicated, anyone can inspect the logic and verify the outcome. That transparency cuts both ways: a bug is just as visible to an attacker, and a deployed contract usually cannot be changed unless the developers built in an upgrade path. Most tokens, exchanges and lending markets are collections of smart contracts.
Related terms
More in Fundamentals
Proof of Space · Proof of Stake (PoS) · Proof of Work (PoW) · Public Key · Public Ledger · Satoshi · Soft Fork · Stablecoin · Ticker Symbol · Timestamp Server · Token Burn · Token Metadata