Physical Address
304 North Cardinal St.
Dorchester Center, MA 02124
Physical Address
304 North Cardinal St.
Dorchester Center, MA 02124
A keeper bot is the automated agent that liquidates risky DeFi loans and keeps protocols solvent. Here is how it works, whether it pays, and the risks.
A keeper bot is an automated program that watches a DeFi protocol and executes needed upkeep, such as liquidating risky loans, in exchange for a reward paid by the protocol.
If you searched “keeper bot” and expected goalkeepers, this is the other kind. In crypto, a keeper bot is software, not sport. It runs quietly in the background of lending markets, perpetual exchanges, and yield vaults.
Most people meet keeper bots the hard way. A loan gets liquidated, the collateral vanishes, and the borrower wants to know who took it. The answer is usually a keeper bot that spotted an unhealthy position and acted first. This guide explains what keeper bots do, how they earn, and what they mean for both borrowers and would-be operators.
A keeper bot is an automated agent that monitors a DeFi protocol and carries out tasks the protocol cannot do on its own. Smart contracts are passive. They wait to be called. So protocols need an outside actor to press the right button at the right moment, and keeper bots are that actor.
The name causes confusion because “keeper” also means goalkeeper. In crypto, the term borrows the idea of someone who keeps things in order. A keeper keeps the protocol healthy. It is the automated janitor that keeps DeFi solvent while everyone else sleeps.
Keeper bots sit underneath the wider market of lending and crypto derivatives. Every loan, every leveraged position, every vault relies on someone acting when conditions change. Without keepers, bad loans would sit unresolved and protocols would slowly bleed.
The reward is what makes it work. A protocol pays the keeper a bonus or fee for doing the job. That incentive turns dry maintenance into a small business, which is why thousands of bots compete for the same work.
A keeper bot runs a simple loop, over and over, as fast as it can. It watches, it checks, it acts, then it repeats. The speed and cost of that loop decide whether the bot earns anything at all.
The bot starts by reading data. It pulls prices from an oracle or price feed and tracks the health of every position it cares about. Health is usually a ratio, such as a loan’s collateral value against its debt. When that ratio crosses a danger line, the position becomes eligible for action.
Then the race begins. The bot builds a transaction to liquidate or settle the position and submits it to the network. Because many bots see the same opportunity, whoever lands the transaction first wins the reward. Everyone else wastes gas.
The math is unforgiving. The reward must beat the gas cost, or the bot loses money even when it wins. This gas arbitrage is the heart of the job, and it grows tighter as competition rises.
Here is the loop in plain steps:
Keepers also settle and liquidate positions in leveraged markets like perpetual futures, where prices move fast and eligible positions appear in seconds. That speed is why keeper operators obsess over node latency and gas strategy.
Liquidations get the headlines, but they are only one job. Keeper bots handle a range of upkeep that keeps protocols running smoothly. Treating them as pure liquidators misses most of what they do.
Many protocols schedule tasks that need a nudge from outside. A vault has to compound rewards. An auction has to close. An expired contract has to settle. None of that happens on its own, so a keeper does it for a fee.
The table below maps common keeper tasks to the reason each one needs an outside bot.
| Keeper task | Why it needs a keeper |
|---|---|
| Liquidating undercollateralized loans | The contract cannot self-trigger when a price feed moves. |
| Closing debt or collateral auctions | Someone must place and finalize bids on time. |
| Harvesting and auto-compounding vaults | Rewards sit idle until a bot reinvests them. |
| Settling expired perps and options | Expiry needs an external call to finalize payouts. |
| Triggering oracle or parameter updates | Scheduled changes require an on-chain trigger. |
| Executing limit orders on a DEX | Orders fill only when a keeper acts on the target price. |
Yield and staking products lean on keepers too. A liquid staking position or an auto-compounding vault only stays efficient because a bot harvests and reinvests on schedule. Skip that upkeep, and returns quietly leak away.
So the honest picture is broader than liquidation. Keeper bots are general-purpose upkeep workers, and liquidation is just their most visible and most profitable shift.
Three terms get tangled together in almost every search, and untangling them is worth a section. A keeper bot, an MEV searcher, and a Keep3r-style network are related but not the same. They overlap at the edges and differ at the core.
A keeper bot does sanctioned protocol upkeep for a defined reward. The protocol wants the job done and pays for it. The keeper is a welcome participant, not a predator.
An MEV searcher extracts value by reordering, inserting, or sandwiching transactions in a block. Its edge comes from transaction ordering, not from a posted reward. Liquidations are where the two overlap most. A searcher will happily grab a liquidation if it can win the block position, so many liquidation bots are really MEV bots in disguise.
A Keep3r network, along with services like Chainlink Automation and Gelato, is not a bot at all. It is a marketplace or service that outsources keeper work. Protocols post jobs, and independent keepers or the service itself run them. It sits one layer above the individual bot.
The table separates the three cleanly.
| Term | What it really is |
|---|---|
| Keeper bot | Software doing paid, sanctioned upkeep for a protocol. |
| MEV searcher | Bot extracting value through transaction ordering, often via liquidations. |
| Keep3r / Chainlink Automation / Gelato | A marketplace or service that outsources keeper jobs. |
The overlap is real but bounded. A keeper can use MEV tactics to win a liquidation, and a network like Keep3r can coordinate keepers at scale. But the roles are distinct: keepers do jobs, searchers hunt ordering, and networks route the work.
Yes. If you borrow against collateral in DeFi and your position gets unhealthy, a keeper bot is exactly who liquidates it. This is not a bug or an attack. It is the system working as designed, and understanding it helps you avoid it.
Liquidation triggers when your position crosses a threshold. Lending markets track a health factor or loan-to-value ratio. When your collateral value falls or your debt rises past the limit, the position becomes eligible, and a keeper can repay part of your debt and seize collateral in return.
You pay for that. Most protocols charge a liquidation penalty, and part of it becomes the keeper’s bonus. So a sharp price drop can cost you both the seized collateral and an extra fee on top.
The good news is that liquidation is predictable. It follows the rules of collateral and margin, which means you can see it coming and steer around it.
A few habits keep keepers off your position:
Treat the keeper as a smoke alarm, not an arsonist. It only acts once you are already in danger.
Running a keeper bot is possible, but it is a competitive business, not passive income. The idea sounds like free money: watch for liquidations, click first, collect the bonus. The reality is thinner margins and faster rivals than most people expect.
Start with the skill question, because it gates everything. You need coding ability to build and maintain the bot, plus reliable node access so you see chain data with low latency. Off-chain logic decides which positions to hit and when, and that logic never stops needing tuning.
Capital is the second wall. To liquidate a loan, you often need funds on hand to repay the debt before you receive the collateral. Then you hold that seized collateral until you sell it, which exposes you to price swings. A bot with no capital cannot act on the biggest opportunities.
The table lays out the main tradeoffs before anyone commits.
| Factor | The honest reality |
|---|---|
| Coding and infrastructure | Real dev skill plus low-latency node access are non-negotiable. |
| Capital | You often need funds to repay debt and hold seized collateral. |
| Gas and competition | Margins are thin, and faster bots win the same reward. |
Gas wars are where dreams meet the mempool. When many bots chase one liquidation, they bid up gas to win block priority, and the reward shrinks. You can win the transaction and still lose money.
There is a lighter path. Services like Keep3r, Gelato, and Chainlink Automation let you supply keeper work or run jobs without building everything from scratch. For those who want automation without a keeper’s overhead, more accessible tools like copy trading bots exist, though they solve a very different problem. Be clear-eyed: a solo keeper competing on ETH mainnet liquidations is up against well-funded, highly optimized rivals.
Keeper bots fail more often than they succeed, and the failures cost real money. For operators, most losses come from being too slow or too exposed. For protocols, the danger is what happens when keepers stop showing up.
The most common failure is a reverted transaction. Your bot spots a liquidation, submits, and loses the race. The transaction reverts, but you still pay gas. Do this a hundred times a day and the small losses add up fast.
Other failures come from the environment. An oracle can lag or malfunction, so the bot acts on a stale price. Network congestion can delay your transaction past the window. During extreme crashes, positions can fall so far that no keeper can liquidate them profitably, and the protocol is left with bad debt.
Fast markets make this worse. When prices whip around, keeper activity ties directly to funding rates and settlement on perp venues, so a sudden move can flood the network with competing bots at once.
The systemic risk is the quiet one. If liquidations stop being profitable, rational keepers step back, and the protocol loses its cleanup crew exactly when it needs it most. That is why serious protocols design generous incentives and backstops, so keepers keep acting even in chaos. According to the Aave documentation, liquidations are the mechanism that protects lenders from borrower default, which is why the incentive has to hold under stress.
A keeper bot in crypto is automated software that performs upkeep for a DeFi protocol in exchange for a reward. Its most common job is liquidating undercollateralized loans, but it also settles expired contracts, harvests vaults, and closes auctions. Keepers exist because smart contracts are passive and need an outside actor to trigger these actions on time.
A keeper bot does sanctioned protocol upkeep for a posted reward, while an MEV bot extracts value by controlling transaction ordering. They overlap most on liquidations, where a keeper and an MEV searcher may chase the same opportunity. The clean distinction is intent: keepers do jobs the protocol wants done, and searchers hunt profit from block position.
Keeper bots can be profitable, but the margins are thin and the competition is intense. Rewards must beat gas costs, and faster, better-funded bots often win the same liquidation. Profit depends on latency, capital, gas strategy, and the chain you operate on. Many operators break even or lose money before they optimize, so treat it as a competitive trade, not passive income.
Yes, running a keeper bot from scratch requires real coding ability plus reliable node access and off-chain logic. There is a lighter route through services like Keep3r, Gelato, and Chainlink Automation, which outsource or coordinate keeper work. Those still reward technical understanding, so a non-coder can participate at the edges but cannot easily compete head-on with custom bots.
Yes, a keeper bot is exactly what liquidates your DeFi position when it becomes unhealthy. Liquidation triggers when your health factor or loan-to-value ratio breaches the protocol’s limit, and you pay a penalty that partly funds the keeper’s bonus. You avoid it by borrowing well below the maximum, watching your health factor, and adding collateral or repaying before a threshold.
The Keep3r network is a marketplace that connects protocols needing keeper work with independent keepers who run those jobs. It is not a single bot but coordination infrastructure, similar in spirit to Chainlink Automation and Gelato. Protocols post jobs, keepers register and execute them, and the network handles matching and rewards, so protocols do not have to recruit keepers one by one.
Keeper bots are easier to respect once you know which side of them you are on. Pick the action that matches your situation this week.