AlphaZero Explained: How DeepMind's Self-Taught Chess AI Works
In December 2017 DeepMind announced that AlphaZero, a program given nothing but the rules, had taught itself chess in hours and beaten the champion engine Stockfish 8. It changed computer chess for good. Here is how it really works, what the published numbers say, what critics said, and what came after, using only DeepMind's papers and checked sources.
AlphaZero is a program made by DeepMind (Google) that learned chess, shogi and Go by playing against itself, starting from random moves and knowing only the rules. It uses a deep neural network that suggests moves and judges positions, plus a Monte Carlo tree search that checks about 80,000 positions per second (Stockfish 8 checked about 70 million). In DeepMind's 2017 preprint it beat Stockfish 8 by 28 wins, 72 draws and 0 losses in 100 games; in the 2018 Science paper by 155 wins, 6 losses and 839 draws in 1,000 games. It was never released to the public.
What is AlphaZero?
AlphaZero is a general game-playing program from DeepMind, the AI lab owned by Google. It came out of DeepMind's work on Go: AlphaGo beat Lee Sedol 4-1 in March 2016, and AlphaGo Zero (Nature, October 2017) learned Go without any human games. AlphaZero took the same method and applied it to chess and shogi as well.
The first chess results appeared on 5 December 2017 in a preprint titled "Mastering Chess and Shogi by Self-Play with a General Reinforcement Learning Algorithm". The full, reviewed paper was published in the journal Science on 7 December 2018.
What made it famous was not only that it won, but how. No human told it that a bishop is worth three pawns or that a king needs shelter. It found all of that, and its own style, by itself.
How AlphaZero works, in three parts
1. One neural network with two answers
AlphaZero's neural network looks at a position and gives two outputs: a policy (which moves look promising, as probabilities) and a value (how likely each side is to win from here). The network is large and needs special chips: DeepMind ran it on TPUs, Google's AI processors.
2. Monte Carlo tree search (MCTS)
Instead of the alpha-beta search used by Stockfish, AlphaZero uses a Monte Carlo tree search guided by the network. It explores the moves the policy likes, asks the value output how good the resulting positions are, and spends more time on the lines that keep looking good. Because every step needs the big network, it searches far fewer positions: the 2017 preprint gives about 80,000 positions per second for AlphaZero against 70 million for Stockfish 8. AlphaZero had to be much "wiser" per position to make up for it.
3. Learning by self-play
At the start the network knew nothing and played random moves. Then it played games against itself. After each game, the network was trained to predict the moves its own search had chosen and the final result. Better network, better search, better games, better training data: a loop.
The 2017 preprint says the training used 5,000 first-generation TPUs to generate the self-play games and 64 second-generation TPUs to train the network. That is a huge amount of computing power, which is one reason the result was hard for anyone else to repeat.
The published results against Stockfish
| 2017 preprint | 2018 Science paper | |
|---|---|---|
| Games | 100 | 1,000 |
| AlphaZero's score | +28 =72 -0 | +155 =839 -6 |
| Opponent | Stockfish 8, 64 threads, 1 GB hash | Stockfish 8 (TCEC 2016 champion), 44 cores |
| Time control | 1 minute per move | 3 hours per game + 15 seconds per move |
| AlphaZero hardware | 4 TPUs | 4 first-generation TPUs + 44 CPU cores |
The 2018 paper also tested AlphaZero from popular human openings, from the TCEC 2016 opening positions, against a development version of Stockfish and against Stockfish with a strong opening book. AlphaZero won all of those matches too. AlphaZero is famous for giving up material for attack; how often engines really sacrifice is counted in our chess engine sacrifice statistics. Every setting and number is on our page Stockfish vs AlphaZero: the real results, and you can replay the published AlphaZero games.
Why its chess looked so different
Grandmasters were excited less by the score than by the games. AlphaZero often gave up material for long-term pressure, pushed its h-pawn far up the board, and slowly squeezed its opponent until Stockfish had no good moves left. Many found its play more "human" and more beautiful than classic engine chess.
Grandmaster Matthew Sadler and Women's International Master Natasha Regan studied its games in the book Game Changer (New in Chess, January 2019).
The criticism
The 2017 match was criticised, mostly for the conditions Stockfish played under. In an interview with Chess.com, Stockfish co-author Tord Romstad said "the match results by themselves are not particularly meaningful". His reasons:
- The games used a fixed 1 minute per move, so Stockfish could not use its time management.
- Stockfish ran with far more search threads than it had ever been tested with, and with hash tables that were too small for that many threads.
- The Stockfish version used was about one year old.
Grandmaster Hikaru Nakamura said he did not "put a lot of credibility in the results" and that Stockfish "was basically running on what would be my laptop", while AlphaZero ran on special hardware. Others pointed out that Stockfish had no opening book in the 2017 match.
The 2018 Science paper answered much of this: a 3-hour time control, more Stockfish hardware and hash, opening-book and opening-position tests, and still a clear win. But one point remains: because AlphaZero was never released, nobody outside DeepMind could test it.
What came after AlphaZero
- Leela Chess Zero (2018). An open-source project led by Gary Linscott copied AlphaZero's method with volunteers' computers. It won the TCEC Superfinal in Season 15 (2019) and Season 17 (2020). See its profile and Leela vs AlphaZero.
- NNUE in Stockfish (2020). Stockfish added its own, much smaller neural network in Stockfish 12. Read what NNUE is.
- MuZero (Nature, December 2020). DeepMind's next step learned Go, chess, shogi and Atari games without even being told the rules.
Would AlphaZero beat today's Stockfish? It cannot be tested. Stockfish 19 is far stronger than Stockfish 8, and Leela, which uses AlphaZero's ideas, has not won a TCEC Superfinal since 2020. The differences between the approaches are in neural network chess engines.
See all our chess engine profiles. Today's top engines meet in matches like Torch vs Stockfish.
Play these engines yourself. Stockfish 19, Obsidian and Stormphrax are free to play; Reckless, PlentyChess, Viridithas, Berserk, Caissa, Koivisto and Ethereal are Premium bots. They run right in your browser. All engine bots · licences and source code.
Frequently asked questions
How does AlphaZero work?
AlphaZero combines a deep neural network, which suggests moves and estimates who is winning, with a Monte Carlo tree search guided by that network. It learned by playing millions of games against itself, starting from random play and knowing only the rules.
How long did AlphaZero take to learn chess?
According to DeepMind's 2017 preprint, AlphaZero trained for 9 hours (44 million self-play games) and was already stronger than Stockfish 8 after about 4 hours.
Did AlphaZero beat Stockfish?
Yes, Stockfish 8. In the 2017 preprint it scored 28 wins, 72 draws and no losses in 100 games. In the 2018 Science paper it won 155 games, lost 6 and drew 839 out of 1,000.
Can I play against AlphaZero or download it?
No. DeepMind never released AlphaZero or its network. The closest you can get is Leela Chess Zero, an open-source engine built on the same ideas.
Why was the AlphaZero vs Stockfish match criticised?
Critics, including Stockfish co-author Tord Romstad, said the 2017 match used a fixed one minute per move, too small hash tables for the many threads, and a one-year-old Stockfish. The 2018 paper repeated the test with longer games and more settings.
Is AlphaZero stronger than Stockfish today?
Nobody knows, because AlphaZero has not played since 2018. Today's Stockfish is far stronger than Stockfish 8, so most experts think it would be the favourite, but that is an opinion, not a measured result.
Sources and checks
- Silver et al., "Mastering Chess and Shogi by Self-Play with a General Reinforcement Learning Algorithm", arXiv:1712.01815 (5 December 2017): training, hardware, 100-game match, search speed.
- Silver et al., "A general reinforcement learning algorithm that masters chess, shogi, and Go through self-play", Science 362 (6419), 1140-1144 (7 December 2018); DeepMind blog (6 December 2018).
- Chess.com: "AlphaZero: Reactions From Top GMs, Stockfish Author" (quotes from Tord Romstad and Hikaru Nakamura).
- Wikipedia: AlphaGo versus Lee Sedol, AlphaGo Zero, MuZero; Chess Programming Wiki: Leela Chess Zero. All checked 16 October 2026.
Keep learning on Rama Chess
Watch on YouTube
Prefer video? Our channels show real games move by move, with clear explanations.
Play the chess bots from this article on Rama Chess: Leela Chess Zero.