The 3×3 8 puzzle has only 181,440 reachable positions (How many arrangements are there?). With a number that small, a computer can find the minimum number of moves for every single position.

How we checked

  • Each tile you move counts as one move (the same way the app “Slide Puzzle” counts “Moves”).
  • Starting from the solved board, we expanded to the positions reachable in 1 move, then 2 moves, and so on, until every position was reached (breadth-first search). The number of moves it takes to reach a position from the solved board is that position’s minimum.

Distribution of the minimum number of moves

Fewest movesPositions
0–9420
10286
11396
12748
131,024
141,893
152,512
164,485
175,638
189,529
1910,878
2016,993
2117,110
2223,952
2320,224
2424,047
2515,578
2614,560
276,274
283,910
29760
30221
312
  • Every position is solved in 31 moves or fewer.
  • The most common is 24 moves (24,047 positions).
  • The average is about 22.0 moves, and the position right in the middle (the median) is 22 moves.

The reason positions with an even number of moves tend to outnumber their odd neighbors has to do with where the empty space is. With every move, the empty space alternates between the dark and light squares of a checkerboard pattern. So positions with the empty space at the bottom right, in the four corners, or in the center (5 squares) can only be solved in an even number of moves, and positions with it in the other 4 squares only in an odd number. There are 100,800 positions solved in an even number of moves and 80,640 solved in an odd number.

The farthest positions (31 moves)

Of the 181,440 positions, only 2 take 31 moves.

64785321
31 moves
86725431
31 moves
See the 31 moves that solve the first position
64785321
Move 1: 7↓
64857321
Move 2: 4→
64857321
Move 3: 5↑
65487321
Move 4: 8→
65487321
Move 5: 3↑
65438721
Move 6: 2←
65438721
Move 7: 8↓
65437281
Move 8: 7←
65437281
Move 9: 1↑
65437128
Move 10: 8→
65437128
Move 11: 7↓
65431278
Move 12: 5↓
64351278
Move 13: 6→
64351278
Move 14: 3↑
36451278
Move 15: 2↑
36425178
Move 16: 7←
36425178
Move 17: 5↓
36421758
Move 18: 1←
36421758
Move 19: 4↓
36214758
Move 20: 6→
36214758
Move 21: 3→
36214758
Move 22: 2↑
23614758
Move 23: 1←
23614758
Move 24: 4←
23614758
Move 25: 6↓
23146758
Move 26: 3→
23146758
Move 27: 2→
23146758
Move 28: 1↑
12346758
Move 29: 4←
12346758
Move 30: 5↑
12345678
Move 31: 8←
12345678
Solved

By the way, the board with the tiles in reverse order from 8 to 1 (empty space at the bottom right) is solved in 30 moves.

If a multi-tile slide counts as one

Sometimes sliding several tiles at once, in the same row or column as the empty space, is counted as a single move. Checking the same way with this counting:

  • Every position is solved in 24 slides or fewer, and only one position needs 24.
  • The average is about 16.55 slides.
14728365
The position that needs 24 slides when multi-tile slides count as one

The app’s ★1 puzzles

We checked 500 ★1 (3×3) puzzles made the same way the app makes them. Their minimums ranged from 12 to 30 moves, with an average of 22.5 moves.

On a 3×3, the app’s “Hint” works from a table of the minimum moves for every position, just like this article. So following the hints on ★1 solved all 500 puzzles in exactly the minimum number of moves (How to use hints).

On a 4×4, it is not possible to check every position this way. Even so, we know that the farthest positions take 80 moves (The fewest moves for the 15 puzzle).