A smart contract cannot wake itself up. Every liquidation, scheduled payment, limit order, and yield harvest needs someone to submit a transaction, and that someone is a keeper. The entire category exists because of that one limitation, and most of its failure modes come from forgetting it.
Why contracts can't self-execute
A blockchain has no scheduler. A node executes a transaction because a user signed it, and nothing happens otherwise — there is no timer, no cron, no background process. So "automatic" on-chain always means "someone is paid to press the button." The interesting design questions are who that someone is, how they get paid, and what happens when they stop.
The role, and its economics
Keepers watch for a condition — a collateral ratio below a threshold, a block number reached, rewards accumulated, a price crossing a trigger — and submit the transaction that acts on it. Execution is permissionless in most designs, so anyone can be a keeper and the protocol pays a reward drawn from a fee, an auction, or a token emission.
That makes keeper economics gas-price economics. The reward has to cover the cost of a transaction at the moment the condition becomes true, and in congestion the cost can multiply. This single relationship explains most keepers failing: a reward calibrated for 20 gwei is not a reward at 300 gwei, and the job simply does not get done while the protocol believes it has automation.
The networks that exist
Chainlink Automation handles condition- and time-triggered jobs with a decentralised executor set, which is the right choice when liveness matters more than cost. Gelato executes arbitrary contract calls and runs off-chain "Web3 Functions" with on-chain settlement, which suits logic that needs data from outside. OpenZeppelin Defender offers scheduled tasks, monitoring, and relayers, and is often used as the operational layer rather than the execution layer. Keep3r Network is a permissionless job market where protocols post work and keepers compete for it — flexible and cheap, with no liveness guarantee at all.
The choice is between reliability guarantees and pure permissionless liveness. A protocol that needs liquidations to happen should buy guarantees; a protocol automating a low-stakes housekeeping task can accept a race.
Where it breaks
Four failure modes recur.
Reward too low for congestion. The job stalls exactly when gas is expensive, which is exactly when liquidations matter.
Missed execution leaves losses. A liquidation that does not happen at the threshold leaves bad debt that accrues to depositors, so the keeper's reliability is a solvency parameter, not an operational nicety.
Griefing. An attacker can make a job expensive to run without any profit motive — by inflating the work a keeper must do to determine whether the condition holds. Because execution is permissionless, the attacker does not need to be a keeper.
MEV adjacency. A profitable liquidation is a profitable transaction, so private mempools, front-running, and back-running all apply. Any protocol that publishes its liquidation logic is publishing a race, and the winner is whoever pays for latency.
How to design around it
Redundancy first: more than one keeper per job, ideally across providers, with fallbacks if the primary does not fire within a deadline. Second, check conditions cheaply and correctly — a function that reads three oracles per block is a griefing surface, one that checks a stored timestamp is not. Third, alert on missed executions, because a job that silently stopped is worse than one that errored. And fourth, decouple the reward from a fixed number: a reward that scales with gas price is the difference between a job that runs and one that does not.
The ERC-4337 stack changes the shape of the problem in two ways. A paymaster can sponsor gas for the automated call, which means the user does not need a funded balance for the agent to act on their behalf. And a session key can authorise a bounded action — spend up to X on this contract until date Y — so automation can be scoped to what it needs rather than holding a user's full permissions.
Together those turn automation from "keep a hot wallet funded and hope" into something with a defined blast radius. For anything user-facing, that is the version worth building.
References
Next, read Decentralized Oracles 101. More in Infrastructure & Scaling.