DeFi

Smart Contract

Self-executing code on a blockchain that runs exactly as written when its conditions are met, with no party able to intervene.

A smart contract is a program stored on a blockchain. It holds funds and rules and runs automatically when triggered, whether to release a payment once a deadline passes or to swap one token for another. Once deployed, it usually cannot be changed.

Ethereum popularized them in 2015. The strength is that no one can renege; the code enforces the deal. The weakness is the same. Bugs are permanent and exploitable. The 2016 DAO hack drained roughly $60 million through a flaw in code that otherwise worked as written.

Related terms