Illustrated Guide

The DAO Hack: The Heist That Split Ethereum in Two

In June 2016 an anonymous attacker used a reentrancy bug to drain 3.6 million ETH from The DAO — and Ethereum's attempt to rewrite history gave birth to a rival chain called Ethereum Classic.

9 minutes • 16 illustrated steps • sourced from Junion's explainer

Source video

The DAO Hack: Story of Ethereum Classic

Channel: Junion

Watch on YouTube

What was The DAO hack?

The DAO was a crowdfunded venture fund built on Ethereum that raised 12.7 million ETH — about $150 million, the largest crowdfund the world had ever seen. On Friday, June 17, 2016, an attacker abused a reentrancy flaw in its splitDAO function, withdrawing ETH over and over before the contract could update balances, and siphoned roughly 3.6 million ETH (about $55 million) into a child DAO. White-hat hackers raced to drain the rest, securing 7.2 million ETH, while the community voted 87% in favor of a hard fork at block 1,920,000 that moved the funds to a refund contract. The original, unaltered chain lived on as Ethereum Classic.

Key Takeaways

  • The DAO raised 12.7 million ETH (about $150 million) in the spring of 2016 — the largest crowdfunding project in history at the time, built as a decentralized hedge fund governed by token-weighted votes with a 20% quorum.
  • On June 13, 2016, a Cornell computer science professor found a reentrancy bug on line 666 of the code; Slock.it swapped two lines in the DAO 1.1 framework, but deployed contracts are immutable, so the live DAO stayed vulnerable.
  • On Friday, June 17, the attacker recursively called splitDAO, draining about $55 million at roughly $8 million per hour while ETH flash-crashed from $20 to $15.
  • White-hat 'Robin Hood' hackers used the same exploit to secure 7.2 million ETH (55% of The DAO), leaving all funds time-locked for 41 days behind a 27-day wait plus a 14-day debate window.
  • A community vote (one ETH, one vote) showed 87% support for a hard fork at block 1,920,000 that moved the funds to a refund contract — even though a signature on the attacker's open letter later proved invalid.
  • The unaltered original chain survived as Ethereum Classic; the attacker's 3.6 million ETC would have been 3.6 million ETH worth over $7 billion had the fork never happened.

What Was The DAO?

Before the hack, The DAO was Ethereum's flagship experiment: a crowdfund, a venture fund and a democracy compressed into one smart contract.

  1. 1

    June 13, 2016: a bug on line 666

    It's a Monday in June 2016, and a Cornell computer science professor is reading The DAO's code line by line. For months he had argued the project should be put on hold; today he finds a serious vulnerability — a bug sitting on line 666 — that could let a hacker make unlimited, ATM-like withdrawals. Four days later, the warning would be proven catastrophic.

    The DAO contract source code in an editor beside a June 13 2016 calendar, the day the line 666 bug surfaced
    It began with one researcher reading one function.Watch at 0:06
  2. 2

    The DAO, spelled out

    DAO stands for Decentralized Autonomous Organization: an organization whose rules live in code rather than in managers and paperwork. The idea behind this one was crowdfunding taken to its logical extreme — instead of many funds for many projects, there would be one fund to rule them all, run entirely on Ethereum.

    DAO spelled out as Decentralized Autonomous Organization, the definition behind The DAO crowdfund on Ethereum
    No bosses, no offices — just code.Watch at 2:10
  3. 3

    Every investor was also a voter

    At launch, investors received 100 DAO tokens for every ETH deposited. Tokens granted governance and represented a share: holders could submit proposals — say, invest $1 million for a 10% stake in company XYZ — and everyone else voted yes or no. If a proposal passed verification and reached a quorum of 20% of all tokens, The DAO transferred the ether automatically, and any profits flowed back to the treasury. It was, in effect, one big decentralized hedge fund.

    DAO token holder with 300 tokens worth 3 ETH voting on a proposal to invest $1M for 10 percent of company XYZ
    Tokens weren't just shares; they were votes.Watch at 2:36
  4. 4

    The largest crowdfund in history

    The sale page's live counter told the story of the frenzy: DAO tokens minted, ETH pouring in, a hard deadline of May 28. By the time the sale closed, The DAO had raised 12.7 million ETH — worth about $150 million at the time and the largest crowdfunding project the world had ever seen. The contracts had gone live on April 30, audited repeatedly by Ethereum developers, and from deployment onward not even Slock.it, the company behind it, could change a line of the protocol.

    The DAO token sale dashboard with live counters for DAO tokens created, ETH raised and the 28 May deadline
    The counter that broke every crowdfunding record.Watch at 4:02

Inside the Reentrancy Exploit

The bug wasn't exotic — it was an order-of-operations mistake that let withdrawals repeat before balances caught up.

  1. 5

    The exit hatch: splitDAO()

    To protect minority holders from being outvoted, The DAO included a split function: anyone who strongly disagreed with the majority could call splitDAO and move their ether into a child DAO of their own. The standard procedure was to run a split alone, create the child DAO, then file a proposal to send the money back to your own wallet. That innocuous exit hatch would soon become the attack route.

    A red ETH token splitting from the voting bar above the splitDAO() call, the exit function the attacker abused
    The exit hatch nobody planned to use as a siphon.Watch at 3:51
  2. 6

    The two-line fix that stayed on GitHub

    When the June 13 disclosure landed, Slock.it acknowledged the exploit but called an attack unfeasible, and a fix was committed to GitHub: swap two lines so the balance is updated before the payout. The catch was fatal. Smart contracts deployed on April 30 could never be edited, so the fix only lived in the DAO 1.1 framework — an entirely separate contract set that didn't exist yet. The live DAO kept paying out first and recording it later.

    The two Solidity lines that fix reentrancy: calling rewardAccount.payOut before updating paidOut[_account]
    Two lines, four days too late.Watch at 6:38
  3. 7

    An ATM that pays before it debits

    The flaw is easiest to feel as the video frames it: picture an ATM that hands you cash before updating your balance. You withdraw $10 — and before it records the withdrawal, you ask for another $10, and another, until the machine is empty. That is a reentrancy attack: the contract sends ether to a requesting contract, and mid-payout the requester calls it again, because the balance check still hasn't been written down.

    ATM dispensing banknotes, the analogy for a smart contract that pays out before updating the caller's balance
    Ask again before the balance updates — forever.Watch at 6:47
  4. 8

    Proposal #59 and the seven-day window

    On that Friday — four days after the disclosure — the trap was already armed. A split proposal, memorably named 'lonely, so lonely', sat as proposal number 59. Splits carried a standard seven-day debate period, and nobody joined, because a solo split was perfectly normal procedure. When the window closed, the attacker called splitDAO and the drain began; to Etherscan watchers it looked like the contract was recursively calling itself, over and over, hundreds of times.

    The DAO logo with an arrow paying ETH out to a child DAO, the route proposal 59 used to drain The DAO
    A routine split, filed by nobody suspect.Watch at 5:38
  5. 9

    $8 million an hour, on repeat

    Ether flowed from the main DAO into the attacker's child DAO — the 'Dark DAO' — at a rate of about $8 million per hour, each withdrawal triggered again before the last one was recorded. Token holders watched on Etherscan as the recursion scrolled down the screen. The market reacted instantly: ETH flash-crashed from $20 to $15 on the news, and within the first six hours roughly 30% of The DAO's ether was gone before the attack mysteriously stopped working.

    Etherscan internal transactions with loop arrows around splitDAO, the recursive calls that drained The DAO
    One function, called hundreds of times.Watch at 6:06

The Race to Empty the DAO

With most of the funds still inside, white-hat hackers ran the same exploit to rescue them — and then the clock started.

  1. 10

    Robin Hood's white-hat counterattack

    In Rio de Janeiro, developer Alex van de Sande woke up to a Skype feed blowing up — 'remember that huge unhackable pile of money? It's been hacked.' He and a group of self-styled Robin Hood hackers would drain the remaining funds and return them, but their first attempt missed its window thanks to a Brazilian ISP outage ('we felt like the worst hackers in history'). The second attempt worked: whales donated six million DAO tokens, the team infiltrated split number 78, and out-raced the attacker to secure 7.2 million ETH — 55% of The DAO.

    Robin Hood white hat message stating 7.2M ether from The DAO sits in a child DAO while plans attack the rest
    The good guys had 30 minutes and bad internet.Watch at 9:56
  2. 11

    41 days until the hacker could cash out

    All the rescued and stolen ether now sat in child DAOs — the White Hat DAO and the Dark DAO — behind multiple locks: a 27-day waiting period before any proposal, then a regular two-week debate before funds could leave. Added up, that meant 41 days until the hacker could cash out what amounted to about 5% of Ethereum's entire supply. Those 41 days became the countdown for something far more drastic than another exploit.

    Red 41 days countdown on a dark background, the timelock before the DAO hacker could cash out the stolen ether
    The longest 41 days in Ethereum's history.Watch at 10:44

The Fork That Split Ethereum

Rewrite history to undo the theft, or let the code stand? The community chose — and a rival chain was born.

  1. 12

    'Yours truly, The Attacker'

    One day after the initial attack, an open letter appeared in The DAO's Slack, signed with a private key. The author claimed to have 'lawfully' earned about 3.6 million ether by using an explicitly coded feature, and warned that any soft or hard fork 'would permanently and irrevocably ruin all confidence' in Ethereum. Later inspection showed the signature was invalid — so the true attacker's identity, and even whether this was the attacker, remains unknown.

    The Attacker's open letter claiming 3.6M ether as a lawful reward and warning any fork would ruin confidence
    The attacker claimed a reward, not a theft.Watch at 12:48
  2. 13

    87% voted to rewrite history

    The debate split into two camps. Purists argued code is law: the attacker was closer to a smart lawyer reading contract terms, and Ethereum itself had never been hacked — just one poorly written contract. The other side answered that The DAO held roughly 15% of all ether and was simply too big to fail, an echo of the 2008 bailouts. A carbonvote where one ETH equaled one vote showed 87% support for a fork — though, as the page itself noted, only a small slice of the supply ever voted.

    Carbonvote page for TheDAO Hard Fork showing a dominant green YES share at block 1894000 with red NO minority
    87% said yes — of a small, contested electorate.Watch at 15:10
  3. 14

    Block 1,920,000: the hard fork

    At block 1,920,000, nodes around the world upgraded to software that did what blockchains were never supposed to do: it rewrote history. Every transaction involved in the hack was undone and all ether from The DAO and its child DAOs — including the Robin Hood hoard — was moved into a refund contract, where legitimate investors could withdraw 1 ETH per 100 DAO tokens. No hacker had forced this rewrite; the community had voted it into existence.

    Forked versus Original chain diagram showing Ethereum splitting at the DAO hard fork, block 1920000
    Two chains, one history.Watch at 15:31
  4. 15

    The chain that refused to forget

    But the original blockchain — the one containing the hack — kept growing. Miners who opposed the fork continued mining it, transactions kept flowing, and the very next day the exchange Poloniex listed the old chain's coin at about $2. It became known as Ethereum Classic, the original unaltered Ethereum. Anyone who held ETH before the fork now held both ETH and ETC; idealists who believed immutability meant immutability finally had a chain that agreed with them.

    Ethereum Classic title card reading Build Unstoppable Applications for the original unaltered Ethereum chain
    The original chain got a new name.Watch at 15:50
  5. 16

    The attacker's consolation prize

    The fork worked — the hacker never touched the stolen ETH. But the child DAOs existed on both chains, so the attacker walked away with about 3.6 million Ethereum Classic, worth roughly $150 million when the video was made. Had the fork never happened, that same 3.6 million ETH would be worth over $7 billion today. Ethereum moved on, wiser: smart contracts, developers concluded, are like self-driving cars — and since The DAO, there have been no more bailouts.

    3.6M ETC worth $150,000,000 on a green network background, the attacker's haul after Ethereum's DAO hard fork
    The hack paid out — just on the other chain.Watch at 17:16

Frequently Asked Questions

What was The DAO?

The DAO was a venture capital fund built as smart contracts on Ethereum, launched by the Slock.it team (with Christoph Jentzsch as lead developer) on April 30, 2016. Investors received 100 DAO tokens per ETH and voted on investment proposals with a 20% quorum. It raised 12.7 million ETH — about $150 million — making it the largest crowdfund in history at the time, and it is now retroactively called 'the Genesis DAO'.

How much ETH was stolen in The DAO hack?

The attacker drained roughly 3.6 million ETH — about $55 million at June 2016 prices — at a peak rate of $8 million per hour by recursively calling the splitDAO function. White-hat hackers using the same technique secured another 7.2 million ETH, about 55% of The DAO's total, before the attacker could reach it.

What is a reentrancy attack?

Reentrancy happens when a contract sends funds to an outside contract before updating its internal balances, letting the recipient call back in and withdraw again mid-transaction — like an ATM that pays cash before recording the debit. The fix is to update balances before paying out. The DAO's maintainers wrote that fix, but it shipped in the DAO 1.1 framework while the deployed contract could never be edited. Reentrancy exploits still hit DeFi protocols today.

Why did Ethereum hard fork after The DAO hack?

Because all stolen and rescued funds were time-locked for 41 days, the community had a window to act — and The DAO held around 15% of all ETH, a stake too large to ignore. After an 87% vote in favor, Ethereum executed a hard fork at block 1,920,000 that undid the hack's transactions and moved the funds to a refund contract. Vitalik Buterin was unapologetic about pushing it, dismissing the extreme 'code is law' position as silly.

What is Ethereum Classic?

Ethereum Classic (ETC) is the original, unaltered Ethereum chain — the one that still contains The DAO hack. Miners who opposed the fork kept it alive, and exchanges listed it the very next day at around $2. Pre-fork ETH holders received equal amounts of ETH and ETC. It retains a community of immutability purists, but it never matched Ethereum's momentum and hosts only a fraction of its protocols.

Was The DAO hack illegal?

Unknown — and never tested in court. The attacker's open letter argued the withdrawal used an explicitly coded feature of the contract, making it a lawful claim rather than theft, though the letter's signature later proved invalid. The pro-fork side considered the act ethically wrong and most likely illegal, but no one was ever charged, and the attacker's identity remains one of crypto's greatest mysteries.

Continue the Story

References