GUIDE & REFERENCE

The most moves a 15 puzzle can take — and what that number means

Find out the most moves an optimal 15-puzzle solution can take, how that compares with the 8-puzzle, and what this site's 4×4 solver does and does not claim.

God's number for the 15 puzzle is the length of the longest shortest path: the most single-tile slides a solvable 4×4 board can require. For the usual goal, with the blank in a corner, that number is 80. Seventeen starting positions need all 80 of those moves.

The figure is a shortest-path length, counted one tile at a time. It is not a casual play-through.

What God's number is for the 15 puzzle

God's number, on this puzzle, is a maximum over solvable starts: for each start, take the length of a shortest solution; then take the largest of those lengths. Positions that cannot be solved do not have a solution length and are not part of the maximum.

Wikipedia's article on the 15 puzzle states that lengths of optimal solutions range from 0 to 80 single-tile moves, and that there are 17 configurations requiring 80 moves. The On-Line Encyclopedia of Integer Sequences entry A087725 lists the maximum number of moves required for the n×n generalization as 0, 6, 31, 80 for n = 1, 2, 3 and 4. MathWorld's "15 Puzzle" entry records the same sequence and cites A087725 and Brüngger, Marzetta, Fukuda and Nievergelt (1999).

How the 80-move figure is counted

The 80 is a count of single-tile slides: each time one tile moves into the blank, that is one move. There is a second convention, the multi-tile metric, in which sliding several tiles in a straight line counts as one move. Under that metric, Wikipedia records a maximum of 43. The two numbers answer slightly different questions; the figure this page is about is the single-tile one.

How this compares with the 8-puzzle

The 8-puzzle is the same question on a 3×3 board. There the longest shortest path is 31 moves, and only two starts sit at that length: the two hardest 8-puzzle positions. OEIS A087725 places that 31 next to the 15-puzzle's 80 in the same sequence.

On the 3×3, a shortest path can be found directly: A* with Manhattan distance is the usual method, and this site's 3×3 solver also returns a shortest path. That is why the 31-move boards can be typed into the 3×3 solver and compared with the published length.

The 15-puzzle is larger, and a shortest-path search is a different undertaking. The comparison is about the same definition at two sizes, not about running the same short 3×3 program on a 4×4 board.

Impossible boards are a different question

A start can fail to have a solution at all. The classic example is the unsolvable 14-15 arrangement, in which 14 and 15 are swapped and everything else is already in place. That board is not a long 15-puzzle; it is not a 15-puzzle with a solution. God's number only ranges over the boards that can be finished by sliding.

What this site's 4×4 solver does — and does not claim

The solver accepts numbered 3×3 and 4×4 boards. On 3×3 it returns a shortest path. On 4×4 it returns a working path: a sequence of legal slides that reaches the goal, when the board is solvable.

That distinction matters here. A working path uses only legal slides and ends at the goal; a shortest path is a working path of minimum length. A working 4×4 path can therefore be longer than a shortest path for the same start. If you enter a difficult 15-puzzle and the 4×4 solver comes back with a path, the length of that path is not a check against 80, and it is not a counter-example if the number is larger than 80. It is a working route, not a claim about God's number.

If you want to finish a 15-puzzle by hand instead, the 4×4 method in the solving guide reduces the border first — top row, then left column — and then treats what remains as a 3×3. For a quicker warm-up, play the 3×3 number puzzle.

QUICK ANSWERS

Frequently Asked Questions

What is God's number for the 15 puzzle?

It is 80, counting single-tile slides, for the usual goal with the blank in a corner. That is the most moves a shortest solution can take on a solvable 4×4 start.

How many 15-puzzle positions require that many moves?

Seventeen configurations require 80 single-tile moves, according to Wikipedia's 15-puzzle article.

Is this the same idea as the hardest 8-puzzle?

Yes: both ask for the longest shortest path. On the 8-puzzle the length is 31 moves, and there are two such starts. On the 15-puzzle the length is 80, and there are seventeen.

Can I confirm an 80-move solution with this site's 4×4 solver?

No. The 4×4 mode returns a working path and does not claim that the path is shortest, so its length cannot be read as God's number, and a longer result does not contradict the 80-move figure.

How do I solve a 15 puzzle by hand?

Finish the top row, finish the left column, then solve the remaining 3×3. The solving guide walks through that reduction.

Are 80 moves counted as single-tile slides?

Yes. Each move is one tile sliding into the blank. If several tiles in one line may slide together as a single move, Wikipedia records a different maximum, 43. That is a different metric.

Where is the 80-move maximum recorded?

OEIS A087725 lists 80 as the maximum for the 4×4 board. MathWorld cites that sequence and Brüngger, Marzetta, Fukuda and Nievergelt (1999). Wikipedia states both the 80-move maximum and the count of 17 configurations.

CONTINUE EXPLORING

Keep Going

PUT IT INTO PRACTICE

Ready to Slide or Solve?

Practice on a fresh 3×3 board in your browser, or enter a scrambled puzzle into the solver to inspect every move.