Sokoban is the legendary Japanese box-pushing puzzle game that has challenged minds since 1981. Push crates onto target locations in the fewest moves possible — but be careful, you can only push boxes, never pull them. One wrong push and you may need to restart the entire level. This browser version features 15 handcrafted levels of increasing difficulty, from simple introductory puzzles to devious multi-box challenges. Each level is a self-contained spatial puzzle requiring you to plan your path carefully. The game saves your progress, so completed levels are tracked and you can replay any level to improve your move count. Sokoban is pure logic — no time pressure, no enemies, no randomness. Just you, the boxes, and the targets. It is one of the most studied puzzle games in computer science and remains a benchmark for AI research. Can you solve all 15 levels?
How to Play Sokoban
Use arrow keys or WASD to move your character (the green circle) around the warehouse. Walk into a box to push it one space in the direction you are moving. Boxes can only be pushed, never pulled, and you cannot push two boxes at once.
Push all boxes (brown squares) onto the target locations (red diamonds). When a box is on a target, it turns golden. When all targets are covered, the level is complete. On mobile, use the on-screen D-pad or swipe in the direction you want to move.
Press Z or tap the Undo button to undo your last move — you can undo multiple times to backtrack. Press R or tap Reset to restart the current level. The move counter tracks your total moves for the current attempt.
Sokoban Tips & Strategies
- Plan before you push — once a box is in a corner or against a wall with no target, the level may be unsolvable.
- Work backwards mentally: picture where boxes need to end up, then figure out how to get them there.
- Avoid pushing boxes against walls unless the target is along that wall — wall-pinned boxes have limited movement options.
- Use the undo button freely. It is not cheating — it is the primary tool for learning each puzzle.
- Focus on the hardest box placement first. Solve the trickiest positioning early when you have the most room to maneuver.
- Count the open spaces between boxes and walls. Tight corridors require precise sequencing of pushes.
Frequently Asked Questions
How many levels are there?
There are 15 levels ranging from simple 1-2 box introductory puzzles to complex multi-box challenges on larger grids. Your progress is saved automatically — completed levels are marked with a checkmark in the level selector.
What happens if I get stuck?
Press Z or tap Undo to reverse your last move — you can undo as many times as needed, all the way back to the start. You can also press R or tap Reset to restart the level entirely. There is no penalty for undoing or resetting.
Can a level become unsolvable?
Yes. If you push a box into a corner with no target, or pin two boxes against each other in a way that neither can be moved to its target, the level is deadlocked. Use Undo to backtrack, or Reset to start over.
Does Sokoban work on mobile devices?
Yes! The game includes an on-screen D-pad for mobile play, and also supports swipe gestures. The board scales to fit your screen. All buttons (Undo, Reset, Level Select) are touch-friendly.