Guides & news
Categories
English
English
Tower of Hanoi online: logic puzzle with disks
Loading game…
Theater stage with a magician wearing a turban, three rods with turquoise disks stacked by size, and a pianist playing in the background.
👍 0 Logic games

Tower of Hanoi online: logic puzzle with disks

f w x r

About Tower of Hanoi online

The Tower of Hanoi is a mathematical puzzle invented in 1883 by the Frenchman Édouard Lucas, and more than a century later it is still used in math, programming and psychology classes. In this online version, set in a small theater with a magician and a pianist, you have three rods and a stack of disks of different sizes: your mission is to move the whole tower to another rod following a few very simple rules. If you like challenges that are solved by thinking rather than by reflexes, check out our logic games.

Lucas accompanied the puzzle with a legend: in a temple, some monks move 64 golden disks and, when they finish, the world will end. Don't worry: it would take 18,446,744,073,709,551,615 moves, so at one move per second it would take hundreds of billions of years.

How do you play the Tower of Hanoi in Tower of Hanoi online?

The Towers of Hanoi have only three rules:

  1. You can only move one disk at a time.
  2. You can only take the disk that is at the very top of a rod.
  3. You can never place a big disk on top of a smaller one.

The challenge is to do it in as few moves as possible. The minimum possible is 2n − 1, where n is the number of disks: 3 disks = 7 moves, 4 disks = 15, 5 disks = 31, 6 disks = 63 and 7 disks = 127. Each extra disk doubles the work.

Tower of Hanoi online controls

PC

  • Mouse: click the top disk of a rod and then the destination rod (or drag it)

Mobile and tablet

  • Tap: tap or drag the disk to the rod where you want to put it

What do you learn in Tower of Hanoi online?

  • Planning: thinking several moves ahead before acting.
  • Recursive thinking: to move a tower of 5 disks, you first have to move the 4-disk tower on top of it.
  • Powers of 2 and exponential growth, visually.
  • Patience and managing frustration when redoing an attempt.

Recommended for ages 7 and up.

Tips for playing better: Tower of Hanoi online

  • The smallest disk moves every other turn: on even turns, make the only legal move that doesn't involve it.
  • Always move the small one in the same direction. With an odd number of disks, its first move goes to the final rod; with an even number, to the auxiliary rod.
  • Think in sub-towers: your real goal is to free the biggest disk so you can put it in place; everything else is just moving the tower above it twice.
  • Count your moves and compare them with the minimum (7, 15, 31…). If you go over, look for the step where you undid your work.

Tower of Hanoi online FAQ

What is the solution to the Tower of Hanoi with 3 disks?

Calling the starting rod A, the middle one B and the final one C: A→C, A→B, C→B, A→C, B→A, B→C, A→C. Seven moves, the minimum possible.

Why is the Tower of Hanoi online used in class?

Because it combines logic, math and executive functions: it forces you to plan, follow rules and discover a pattern that then works for any number of disks.

Additional information: Tower of Hanoi online

Game type: Logic and mathematical reasoning puzzle
Recommended age: Ages 7 and up
Technology: HTML5
Platform: Web browser (PC, tablet and mobile)

Enjoyed Tower of Hanoi online? Also try Queens game, rubiks cube online or Tic Tac Toe for 2 Players. Find more Logic games and hundreds of free games on LudoRex.

🏷 Logic games, Math Games, Puzzle games, Educational Games for Kids Aged 8 to 9

Last update:

Games like Tower of Hanoi online

View all ›
Queens Tic Tac Toe for 2 Players Guess the Footballers Tiny Heist fuzzies Rubik's Cube Online: Solve the 3x3 Cube in 3D Tangram Online: Geometric Shapes Puzzle Where is the Water: the Crocodile Puzzle Game Snail Bob 5 Adam and Eve (Adam y Eve) 100 Doors: Escape Room Apple Worm: the Apple-Eating Worm Game 10x10 Pac Xon: trap the ghosts by filling in the map Bloxorz: 3D Puzzle of Rolling the Block into the Hole Suguru Online: the Number Logic Puzzle Plumber: Plumber’s Pipe-Connecting Game Dream Pet Link: Match Cute Animal Pairs