A smart contract is a self-executing contract that doesn’t require a third-party intermediary to exchange value. You can think of a smart contract like a digital vending machine.
When you insert a coin into a vending machine, it’s automatically held in escrow (within the vending machine) until you pick a snack. Once you pick a snack, the vending machine’s “smart contract” self-executes. Your snack is released to you, and your money is released from the machine’s escrow and joins all the other coins waiting for collection inside the machine.
And if your snack is out of order, the machine gives you a refund.
This is a very primitive example of a smart contract, although there are some key differences.
Smart contracts on a blockchain are transparent and verifiable as the transactions can be verified by all network participants whereas a vending machine is owned by a private company.
Smart contracts have use cases in real estate, insurance, health care, and beyond. They can reduce costs and cut out intermediaries in any industry where value is being transferred. One of the most prominent examples of a smart contract was in the creation of the DAO. The DAO was an investor-directed venture fund that was built off of smart contracts. The DAO was shut down in 2016 after it was a critical vulnerability in the DAO was exploited, leading to a loss of millions of dollars of ETH.