Snake vs AI
Two snakes, one apple supply. Race a pathfinding computer opponent to 15 apples, block its lanes with your body, and do not let it box you in first.
Keyboard: ↑↓←→ or WASD to steer, P pause, R restart, M mute. Touch: swipe or d-pad.
The machine wants your apples
Snake vs AI puts a second, computer-controlled snake on the board with exactly one job: reach every apple before you do. The AI runs a genuine breadth-first pathfinding search each tick, so it takes real shortest routes, reacts when you cut it off, and punishes lazy lines. First to 15 apples wins the match.
Touching the red snake's body is fatal for you, and the same rule applies to it: if the AI has no safe move, it crashes and respawns a moment later, giving you free seconds of uncontested farming. Forcing those crashes is the heart of high-level play.
How to beat the AI
- Play the spawn, not the apple. Apples spawn anywhere free. Holding the centre means your average distance to the next apple is shorter than the AI's.
- Use your body as a wall. The AI routes around your segments. A long body laid across the middle of the board turns its shortest path into a detour.
- Cut the corner it wants. When you cannot win the race to an apple, drive across the AI's approach lane instead. Either it reroutes and loses time, or it traps itself and crashes.
- Never trade crashes. The AI respawns; you do not. Your death ends the match regardless of the score.
Match rules
One point per apple for either snake, first to 15 takes the match, and your winning score is saved as your best. If you crash at any point, the AI wins immediately.
Frequently asked questions
How does the AI snake decide where to go?
What happens when the AI snake crashes?
What happens if I hit the AI snake?
Can I win by trapping the AI instead of racing it?
Keep playing
Classic Snake
The pure original. One apple at a time, walls that bite back, and a speed that creeps up on you.
Play now → LevelsSnake 2
Level up every five apples. Faster speeds, fresh obstacle layouts, and a proper difficulty curve.
Play now → No wallsInfinite Snake
The board wraps around forever. Chain apples fast to stack a combo multiplier up to 8x.
Play now → 60 secondsSpeed Snake
Sixty seconds on the clock. Gold apples pay triple. Pure arcade time attack.
Play now →