Catch The Cat: How the Cat Decides Where to Run
6 November 2026· 5 min read
Short answer
The cat only considers neighbouring cells that are strictly closer to the board edge than where it stands, and among those it moves to whichever has the most distinct shortest escape routes. It never moves sideways or backwards — so you win the moment no forward cell is left, long before the cat is surrounded.
Catch The Cat looks like a game about building a fence. Tap dots, box the cat in, win. Played that way it is frustrating and feels arbitrary — the cat slips through gaps you were certain you had closed.
It is not arbitrary. The cat follows two rules, and once you know them the game changes shape completely, because one of those rules hands you a much easier win condition than the one you have been playing for.
Everything here comes from the game’s source, which is open and readable.
The board
| Grid | 11 × 11 hexagonal, 6 neighbours per cell |
| Escape cells | 40 (the whole outer ring) |
| Interior cells | 81 |
| Cat’s start | dead centre, 5 steps from the nearest edge |
| Walls at the start | 8, placed at random |
Those 8 opening walls matter more than they look. They are the only reason the game is winnable: you get one tap per cat move, so without a head start the cat reaches the rim before you could ever close it off.
Rule one: the cat never moves sideways or backwards
Every cell on the board knows how many steps it is from the nearest edge. The game works this out by flooding inward from the whole outer ring, so the centre is 5, the ring around it is 4, and so on.
When the cat moves, it builds a list of candidate cells like this:
// the cat's own move list, from the source
this.neighbours.forEach(function (n, index) {
if (n !== null && !n.isWall && n.distance < this.distance) {
candidates.push(index);
}
});
Read the condition: n.distance < this.distance. Strictly closer to the edge. Not equal. A cell at the same distance is not a candidate. A cell further in is not a candidate.
The cat has six neighbours and will often refuse five of them.
Why this is the most useful thing to know
There are two separate ways to win this game, and the source has a different message for each:
“The cat has nowhere to go. You win!” — every neighbour is a wall.
“The cat gives up. You win!” — there are open cells, but none is closer to the edge.
The second is the one that matters, and it fires much earlier. You do not have to build a ring. You have to close the cells in front of the cat — the ones at a lower distance than it currently stands on. Leave as many open cells behind and beside it as you like; it will not use them.
So the question to ask before each tap is not “where is the gap in my fence”. It is: which cells would take the cat closer to the edge, and can I close them? Early on the cat has up to six of those. Pressed into a corner it often has one or two, and that is where games are won.
Rule two: it counts routes, not distance
Among the cells that are closer to the edge, the cat picks using a second quantity: routesCount, which is the number of distinct shortest paths from that cell to the edge.
// 1 if you are already on the rim, otherwise the sum over neighbours
// that are closer to the edge than you are
if (this.isEdge) { count = 1; }
else {
this.neighbours.forEach(function (n) {
if (n && !n.isWall && n.distance < this.distance) count += n.routesCount;
});
}
Then it moves to whichever candidate has the highest count.
So the cat does not want the shortest way out. It wants the way out that is hardest to cut. A cell with 40 distinct shortest paths is comfortable; a cell with 1 is a cell where a single well-placed wall ends the story, and the cat avoids it even when both are the same number of steps from freedom.
This is the rule behind the behaviour that feels like cheating. You block right next to the cat and it turns and runs the other way — not because it saw you coming, but because your wall shaved one path off a cell that had fifty, which changed nothing, while the other direction still had its full count.
How to actually play it
Four things follow directly from the two rules.
Block ahead of the cat, not beside it. A wall placed level with the cat or behind it is invisible to a creature that only moves toward the edge. Walls at a lower distance than the cat are the only ones it is obliged to care about.
Aim at bottlenecks, not at the cat. Since the cat is counting paths, the valuable cell is the one that many shortest paths run through — usually a narrow point between two existing walls, often several cells away from the cat. Cutting a chokepoint deletes dozens of routes at once. Cutting a cell in open space deletes almost none.
Use the 8 opening walls. Look at where they landed before your first tap. Two walls near each other are a half-made bottleneck and the cheapest structure on the board; your early taps should be completing them, not starting something new in an empty region.
Push it toward a wall cluster, then close the front. The cat gives up when it has no forward cell. The fastest way to produce that is to let it run into a region where the edge-ward cells are already blocked, then seal the one or two that remain. Chasing it across open board gives it six options every turn and you only get one tap.
The thing most people get wrong
The instinct is to build a closed ring, and it is expensive — a ring around a cat that is several steps from the edge needs a lot of taps, and you only have one per turn while the cat spends its turn getting closer.
The cat’s own rules never require you to finish that ring. It resigns the moment the forward direction is gone. Playing for the resignation instead of the enclosure is usually the difference between losing by one tap and winning with a tap to spare.
Play it
Play Catch The Cat on Zunto — free, in your browser, nothing to install. Tap the dots to block them; there is an Undo button, which is worth using while you get a feel for how the cat responds.
One run to try the idea: ignore the cat entirely for your first three taps and complete a bottleneck near the existing walls instead. It feels wrong, and it works more often than fencing does.
Catch The Cat is by ganlvtech and is open source under the MIT licence.
Common questions
- How do you win Catch The Cat?
- You do not need to surround it. The cat only moves to cells that are strictly closer to the edge, so it concedes as soon as none of its neighbours is closer — even with open cells beside it. Blocking the cells ahead of the cat beats building a ring around it.
- Does the cat take the shortest path to the edge?
- Not exactly. It only moves closer to the edge, but among those moves it picks the cell with the most distinct shortest paths out, preferring routes that are hard to cut rather than routes that are short.
- How big is the board in Catch The Cat?
- An 11x11 hex grid: 40 edge cells where the cat escapes and 81 interior cells. The cat starts dead centre, five steps from the nearest edge, and the game begins with 8 randomly placed walls.
- Why does the cat sometimes run away from where I blocked?
- Because it is counting routes, not distance. Cutting one path out of many barely changes that cell's appeal, while cutting the last path out of a cell removes it from the cat's options entirely. Where you block matters more than how close it is to the cat.
Play it
Written by the Zunto team. We host these games and read their source, so the mechanics described here come from the games themselves rather than from guesswork. Spotted something wrong? Tell us.