Eat and the snake grows a square; touch a wall or your own body and the run is over. The board is 20×20 and the snake starts three squares long. Every fifth bite speeds it up a little, so late in a run you have to decide where you are going before you get there. Turn on wrap and the walls stop killing you — you come out the other side instead. The best score is stored in this browser, and nothing is installed.
Every five bites cuts 10 milliseconds off the step interval, down to a floor of 70. Below that there is less time to react than a person needs to change direction.
You may move into the square your tail is leaving, because it empties on the same step. On the step you eat, the tail stays put, so that same move is a crash.
Filling the entire board ends the run as a win. That means all 400 squares, which is rarer than it sounds.
Your best score and the wrap setting live in this browser (localStorage) and are never sent to a server.
Everything in snake follows from one rule: the snake keeps moving. You choose direction and nothing else. Eating adds a square, and touching a wall or your own body ends the run.
What makes the game unusual is how it gets harder. Most games escalate by making the opposition stronger; snake escalates by making your own success the obstacle. Every point you score is another square of board you can no longer use.
The board is 20 by 20, or 400 squares, and the snake starts at length three. Since food is worth one point, the theoretical ceiling is 397 — which is another way of saying the board is entirely snake.
The square behind the head is the neck. Pressing left while travelling right walks straight into it, and the run ends on the input rather than on a decision. Nearly every implementation ignores that key for exactly this reason.
There is a classic bug hiding here. If you block reversal against the queued direction, three fast taps — up, left, down — inside a single step will take you through your own body, because no single tap is the opposite of the one before it.
So this page compares against the direction actually travelled on the current step. However many keys you press between steps, only the true reverse is refused, and the pass-through disappears by construction.
A step takes 0.17 seconds at the start and loses 0.01 seconds every five bites, with a floor at 0.07. Faster than that and the window for a turn is shorter than human reaction time, which converts skill into luck.
The score is just the count of food eaten — no multipliers, no combos. The difficulty curve is already baked into it: the twentieth bite is taken with seventeen more squares of body in the way than the third.
Because of that, a score reads better as a place than as a number. Around length twenty the middle of the board starts to close; past length forty you will trap yourself unless you plan a route rather than chasing the dot.
The first habit to unlearn is driving straight at the food. It works while you are short and it kills you once you are long, because you arrive with no way out. Look at where you will leave the food from, not at how to reach it.
The simplest safe pattern is to circle the edge. Keeping a wall on one side holds your body in a single connected shape and leaves a wide open middle, and you dip inside only when the food appears there.
Chasing your own tail is the other reliable escape. The last square of the tail empties exactly as you arrive, so following it is always legal and buys you time while a better route opens.
There is even a way never to die. Lay out a loop that visits every square once and returns to the start, then simply drive it forever. Mathematicians call that loop a Hamiltonian cycle, and on an even grid like 20×20 one is guaranteed to exist. Playing it is tediously slow, but the fact that perfect play exists tells you what kind of game this is.
Strong players blend the two: follow the cycle as a fallback, cut across it when the food is close and the shortcut is provably safe, and fall back to the loop the moment the board tightens.
With wrap on, the top edge connects to the bottom and the left to the right. One of the two ways to die disappears, and no run ends because you drove off the board.
The late game gets harder, though. Without walls, hugging the edge stops meaning anything, and your body ends up spanning a board with no boundary, so every turn needs a fresh read of which way is still open.
The two modes share one best score. They are the same board and the same food rule, and splitting the record would suggest a comparison the game does not really support.
Food is placed by picking from a list of empty squares. The common alternative — draw a random square, retry if the snake is on it — blows up in attempts exactly when the board is nearly full, which is when a stall is most visible.
Tail collision is resolved to the exact step. The tail square empties as you enter it, so moving there is legal; on the step you eat, the tail stays, so the same move is a crash. Blur that distinction and you get the most infuriating false death in the genre.
The rules live in pure functions with the state passed by value. That makes it possible to compute a hypothetical next step, and it lets tests write a board out literally and assert on it.
Movement runs on a single 30-millisecond timer that accumulates time and applies the current interval. Re-creating the timer whenever the speed changes would silently drop a step at the moment the game accelerates.
The best score and the wrap setting stay in this browser. Nothing is uploaded, so there is no global leaderboard, and clearing site data clears the record.
The snake never stops moving; all you control is direction. Food scores one point and adds one square of length. Touching a wall or your own body ends the run. That is the whole game.
The square directly behind the head is your own neck, so a reversal is an instant crash. Losing a run to one mistimed key is a punishment rather than a rule, so the input is ignored. The check uses the direction actually taken this step, not the queued one — otherwise three quick taps inside a single step let you pass through your own body.
Walls stop being lethal: you leave one edge and arrive at the opposite one. That removes one of the two ways to die, so early play is much easier, and late play is harder, because your body now stretches across a board with no corners to hug.
One point per bite, and nothing else. Length and score rise together, so the score is simply how many you ate — and on a 20×20 board the ceiling is 397, the moment the snake fills every square.
Yes. Use the four-way pad or swipe across the board itself. Nothing is installed, no account is needed, and it keeps working offline.
What this tool bases its numbers on, and how far those numbers go.
The board is 20×20 = 400 squares and the snake starts at length 3. Food is worth one point and one square of growth. The step interval starts at 170 ms, drops 10 ms every 5 bites and stops at 70 ms.After 20 bites the snake is 3 + 20 = 23 squares long and the step interval is 170 − (20 ÷ 5) × 10 = 130 ms.