Maze Generator & Solver
Carve a perfect maze in a fraction of a second, then watch breadth-first search find the one true path from corner to corner.
Maze Generator & SolverLive
recursive backtracker · BFS solve
Controls
Presets
A perfect maze (exactly one path between any two cells) carved by depth-first backtracking, then solved top-left to bottom-right with breadth-first search.
Data Inspector
Cells25²
AlgorithmDFS carve
SolverBFS shortest
Governing equation
Reading this result: A perfect maze has exactly one path between any two cells, so BFS from corner to corner always finds it — here across 625 cells.
Runs locally in your browser — free forever. Scale to the cloud when reality gets heavy.
★ Sign in to save this setupSave your tuned setup, or drop this simulation into your own site, docs, or course page.
How it works
Depth-first backtracking carves passages until every cell is reachable by exactly one route — a perfect maze. Breadth-first search then explores outward from the start, guaranteeing it finds the shortest solution path first.
✦
Ask the AI about this model
The math, the assumptions, real-world uses, or a code translation — explained for this exact simulation.
More CS / AI simulations
Frequently asked questions
Is this maze generator solver tool really free?▾
Yes. Maze Generator & Solver runs entirely in your browser using your device's own compute, so local use is free forever. You only pay Compute Tokens if you scale a job to the cloud.
Do I need to install anything?▾
No. Everything runs client-side in a modern browser — no downloads, no license, no account required to start.
Can I save or share my simulation?▾
Create a free account to save projects, and use a shareable embed or minted DOI to publish a live, interactive version anywhere.
How accurate are the results?▾
The solver uses established numerical methods, but results are for research and educational purposes and should be validated against experiment or professional review before you rely on them.