
LMD GHOST is the specific fork choice rule that Ethereum's proof-of-stake chain uses to decide which block is the current head. If you've read about fork choice in general — the job of picking one tip when the network briefly disagrees — this is the actual algorithm doing that job on Ethereum. The name is an acronym stacked on an acronym, which makes it look more forbidding than it is. Pull the two halves apart and each one describes a concrete design decision that solves a concrete problem.
The short version: GHOST is the part that decides how to weigh competing branches, and LMD is the rule for which votes get counted. Together they let hundreds of thousands of validators, each with a slightly different view of the network, converge on the same head without a coordinator — and do it in a way that's expensive to manipulate. Everything below is unpacking that sentence.
GHOST stands for Greediest Heaviest Observed SubTree. It's an alternative to the rule most people picture when they think of a blockchain: longest chain wins. Under a naive longest-chain rule, you'd resolve a fork by following whichever branch has more blocks stacked on it. Simple, but it throws away information. A block that got orphaned — valid, but not on the winning branch — still had validators vote for it, and longest-chain ignores those votes entirely.
GHOST doesn't throw them away. Here's the mechanism, starting from the last justified checkpoint (the anchor the rule is never allowed to choose against). At each fork in the tree, GHOST looks at the child branches and, for each one, sums the weight of every attestation supporting any block in that entire subtree. Not just votes for the immediate child block — votes for its children, its grandchildren, all of it, rolled up. The branch with the greatest total attesting stake wins that fork. Then the rule steps into the winning branch and does the same thing again at the next fork, and the next, recursing downward until it reaches a block with no children. That leaf is the head.
That's the “greediest heaviest subtree” made literal: greedy because it commits to the heaviest branch at each step without backtracking, heaviest by attesting stake rather than block count, subtree because it weighs whole branches instead of individual blocks. The payoff is that support for a branch accumulates. A block deep in a subtree still contributes its validators' weight upward to the branch it belongs to, so a branch that many validators have been building on becomes progressively harder to dislodge. To overturn it, an attacker can't just publish one longer sequence of blocks — they'd have to out-vote the honest majority's entire accumulated subtree. That's a much taller wall.
Now the votes themselves. Ethereum validators issue attestations constantly — roughly once per epoch each, and with hundreds of thousands of validators that's an enormous stream of signed votes, each pointing at the block its author considers the head. If GHOST counted all of them across all of history, two problems appear. First, the sums would grow without bound and the computation would balloon. Second, and worse, old votes would keep propping up branches everyone has already abandoned.
LMD — Latest Message Driven — fixes both. The rule keeps, for each validator, only that validator's most recent head vote. One vote per validator, always the newest. If a validator attested to block A an hour ago and block B thirty seconds ago, only the B vote has weight; the A vote is discarded, not accumulated. This bounds the computation to one message per validator and, more importantly, keeps the head responsive to what the network believes now rather than what it believed before the last few forks resolved. Stale opinions don't get a vote.
There's a subtlety worth naming, because it's where a lot of the security analysis lives. “Latest message” means the rule has to handle a validator that sends two conflicting messages for the same slot — equivocation. A dishonest validator can try to have its vote counted on two branches at once. The protocol treats equivocation as a slashable offense (double voting is exactly what slashing punishes), and the fork choice includes logic to discount equivocating validators so they can't get their weight double-counted across competing branches. The honest case is simple; most of the hardening exists to close the dishonest case.
The first constraint is scope. LMD GHOST decides the head — it's a liveness and head-selection mechanism, not a safety one. It will happily pick a head at the tip that later gets superseded when more attestations arrive, and that's not a bug; it's the rule doing its job at the live edge. Irreversibility is the finality gadget's job, not fork choice's. On Ethereum the two are paired: LMD GHOST for head selection plus Casper FFG for finality, and the combination is called Gasper. Fork choice operates only in the unfinalized region above the last finalized checkpoint. It can reshuffle recent blocks — a normal reorg — but it is structurally barred from contradicting anything finalized.
The second constraint is adversarial, and it's the reason the deployed rule isn't the textbook version. Researchers found that plain LMD GHOST has exploitable seams. In a balancing attack, an adversary with a small amount of stake feeds different halves of the network conflicting messages, timed so that two branches stay at nearly equal weight and honest validators keep splitting their votes — the head never settles. In an ex-ante reorg, an attacker withholds a block and its attestations, then releases them at the right moment to displace an honest block that validators had already built on. Both attacks exploit timing and the way weight accumulates, and neither requires a majority of stake. So the live rule is hardened.
The main hardening in production is proposer boost. When a validator proposes a block on time, the fork choice temporarily adds a large chunk of weight to that block for the duration of its slot — a boost that decays afterward. This makes a timely, honestly-proposed block hard to override with attestations that were withheld and dumped later, which is exactly what the balancing and ex-ante reorg attacks depend on. Proposer boost is a patch on the accumulation logic: it says a fresh on-time block gets the benefit of the doubt, so an attacker can't quietly out-weigh it with saved-up votes.
Beyond that, the changes are incremental. View-merge and refinements to attestation timing are under research to further close reorg and balancing vectors. And on the longer horizon sits single slot finality, which wouldn't replace LMD GHOST but would shrink the unfinalized window it governs — if blocks finalize almost as fast as they're produced, the region where fork choice can reshuffle anything becomes very thin, and several tip-reorg attacks lose their window entirely. The rule's logic stays; the space it operates in gets smaller.
Now: LMD GHOST is the frame for understanding why Ethereum's head occasionally shuffles at the tip and why a block can quietly orphan. Normal behavior, not malfunction.
Next: Watch proposer boost and its successors. Almost all fork-choice news is incremental hardening against reorg and balancing attacks, not a new rule.
Later: Single slot finality is the shift that would most change LMD GHOST's role — by shrinking the window it governs, not by replacing it.
This explains the algorithm Ethereum uses to pick a head and why it's built the way it is. It is not a claim that this rule is superior to Bitcoin's heaviest-work rule or anyone else's — they're solving the same problem under different assumptions. It says nothing about how many confirmations you should personally wait for, which depends on value and tolerance and lives outside this scope. And it says nothing about price.
The mechanism is the point. LMD GHOST takes the flood of validator votes, keeps only the latest one from each, weighs whole branches by their accumulated stake, and follows the heaviest one down to a leaf. That's how a network of independent nodes agrees on where the chain is right now — while a separate mechanism, finality, makes sure they can never unwind what's already been settled.




