Tower of Hanoi
Move the tower to the far peg, one disc at a time, never big on small.
Loading game…
How to play
- Move one disc at a time, always the top disc of a peg.
- A disc can never be placed on a smaller disc.
- Get the whole tower onto the right-hand peg.
- The fewest moves is 2ⁿ−1: 15 for 4 discs, 63 for 6, 255 for 8.
- Tap a peg, then another, to move its top disc; or drag the disc.
About Tower of Hanoi
Play Tower of Hanoi free online with 4, 6 or 8 discs: drag or tap to move, a move counter against the 2ⁿ−1 minimum, and a hint that always knows the shortest way.
Tower of Hanoi: common questions
- How many moves does the Tower of Hanoi take?
- At least 2ⁿ−1 for n discs: 15 moves for 4 discs, 63 for 6, 255 for 8. The legend's 64 discs would take over 18 quintillion moves.
- Can I move a disc to the middle peg?
- Yes. Any peg is allowed as long as the disc goes on an empty peg or on a bigger disc.
- What is the trick to the Tower of Hanoi?
- Every other move is the smallest disc, and it always circles the pegs in the same direction. Between its moves there's only one other legal move. Follow that and you finish in 2ⁿ−1 moves.
Related games
- Rectangles (Shikaku)1 playerCut the grid into rectangles, one number each, number equals area.Puzzle GamesPlay
- Light Up1 playerPlace lamps to light every cell without two lamps shining on each other.Puzzle GamesPlay