Four in a Row is a two-player strategy game on an upright grid seven columns wide and six rows tall. If you are looking for Four in a Row unblocked for a school laptop, this version runs right in the browser against a friend on the same screen or a computer opponent with three strength levels. The rules fit in one sentence, but good play means reading threats several turns ahead, and that is what keeps rounds tense.
How to Play Four in a Row
Black always moves first. On your turn you choose one of the seven columns, and your disc drops to the lowest empty slot in it. You do not need to aim at the top: clicking or tapping any cell in a column picks that column. The open landing spots are lightly marked, so you can see where each disc would end up.
A column that already holds six discs is full and can’t take more. After every drop the game checks for four touching discs of one color in a straight line. Horizontal, vertical and both diagonal directions all count. The first player to make one wins, and a full board with no line is a draw.
Your First Round, Step by Step
- Pick 2 Player (local) to share the device with a friend, or vs Computer to play alone.
- Against the computer, choose your disc color and a level, then press New game. Choosing black means you open; choosing white lets the computer go first.
- Drop your opening disc in the middle column. Watch where the reply lands.
- Keep an eye on the status line. It says whose turn it is and announces the result.
- Use Undo if you misclick. Against the computer it rolls back to your own last turn, removing the computer’s reply too.
- Resign ends a round you can’t save. The game asks you to confirm before resigning or starting over, so a stray click won’t wipe the board.
The Three Computer Levels
The levels behave very differently, and the code shows exactly how:
- Easy chooses a random legal column every turn. It will often ignore your three-in-a-row, which makes it ideal for learning the shapes.
- Medium scores each possible drop by looking at every group of four cells on the board. It rewards its own threes and twos, weighs blocking your threes slightly more than building its own, and likes the center column. Then it picks at random among its top three choices, so it is solid but beatable.
- Hard searches the move tree with alpha-beta pruning, deepening step by step up to eight moves ahead. It checks central columns first and prefers faster wins. It plays very few loose moves.
There is also an optional Suggest difficulty checkbox next to the level menu. When it is on, three wins in a row nudge the level up one step and three losses in a row nudge it down, with a short note explaining the change.
Four in a Row Strategy That Works
These habits will win you more rounds against people and the Medium level, and keep you alive longer on Hard:
- Start in the center. The middle column touches more possible lines of four than any other, which is also why the computer values it.
- Build two threats at once. One open three gets blocked in a single turn. Two separate winning cells mean your opponent can stop only one.
- Don’t fill the cell under a threat. If your rival needs a specific empty spot to win, avoid dropping a disc directly beneath it. You would hand them a ledge to land on.
- Count in pairs of columns. Before you drop, ask where your opponent’s reply would land in that same column. Many losses come from the disc that lands on top of yours.
- Watch the rows late in the game. As the grid fills, a threat on an odd row (first, third, fifth from the bottom) tends to favor the player who went first. The second player usually wants threats on even rows.
- Play white against the computer sometimes. Defending from the second seat is harder, and it teaches you which shapes to fear.
Mistakes New Players Make
The most common slip is staring at horizontal lines only. Diagonals are easy to overlook, both your own and your opponent’s, so scan them before every drop.
Another is blocking too late. When your opponent has two discs with open space on both ends, a single block may not be enough. Deal with it while it is still a two.
Finally, many players fill the edge columns early. Discs on the sides take part in very few lines, so save those columns for forced moves.
Playing on a Chromebook, Tablet or Phone
The board stands upright, so it fits a phone held in portrait well. Touch, mouse and keyboard all work: the arrow keys move between columns and Enter drops a disc. Your round in progress is saved locally, so closing the tab between classes is fine on the same browser.
The Settings menu holds a few useful options. You can enlarge the text, turn on high contrast, change the spacing, and set the computer’s thinking pause to Fast, Normal or Slow. A “Who moves first” option can also randomize your color at the start of each game against the computer.
Who It Suits and What to Play Next
A round takes only a few minutes, so it works for a short break with a friend at the next desk. Playing the Hard level is a better fit for a longer sit, since each game rewards slow thinking.
If you enjoy it, more games are waiting in board and card games:









