Smart contracts are a type of account that stores smart contract code. They are a special type of Ethereum account that has a balance and can be the target of transactions, but they are not controlled by a user. Instead, they are deployed to the network and run as programmed. User accounts can interact with a smart contract by submitting transactions that execute a function defined on the smart contract. Smart contracts can define rules, like a regular contract, and automatically enforce them via the code.
In addition to smart contracts, there are two other types of accounts on the Ethereum network:
- Externally owned account (EOA): This type of account is controlled by a private key and is used to hold Ether and send transactions.
- Contract account (CA): This is a special type of account where Ether is owned and controlled by a piece of code known as the smart contract instead of an entity.
Smart contract accounts can also be used to enable features beyond what can be accomplished with an externally owned account (EOA) alone. They allow someone other than the account owner to pay for the transaction fees required to submit a transaction to the blockchain, enabling a number of useful operations not otherwise possible. Smart contract accounts can also support account recovery methods that do not rely solely on recovering the underlying keys.