Connect 4

Connect Four · Connect four in a row first

Connect 4

Select Game Mode

← Home
Red
It's Red's turn
Yellow

How to Play

Connect 4 (Samok): Omok Compressed by One Gear

If you've already played Omok, you don't need to relearn anything here. Samok is the same idea with the win condition dropped from five to four. Play a round, though, and the pace feels completely different. Needing one fewer stone means the game is often already decided at a point where an Omok match would still feel relaxed. The four-in-a-row idea itself was made famous worldwide by Connect Four, the board game Milton Bradley released in 1974 [Source: Wikipedia], and Omokboard's version adds a twist: instead of pieces dropping by gravity, you place freely anywhere on a Go-style board.

Objective & Rules

  • The goal is to be first to place four stones in an unbroken row, horizontally, vertically, or diagonally.
  • Red moves first, then players alternate.
  • You can play on any empty intersection, and stones never move once placed.
  • Unlike classic Connect Four, there's no gravity here. Placement is completely free.

Threats Mature a Step Earlier Than in Omok

Needing one fewer stone to win means threats reach critical mass a step sooner too. Just as an open four is essentially a win in Omok, in Samok an open three is essentially a win: block one end and the other still completes four. A shape you might comfortably "watch for now" in Omok is often already too late in Samok.

Why the Center Fight Starts Immediately

A center intersection touches four directions at once (horizontal, vertical, and two diagonals), so a single stone there contributes to multiple lines. That efficiency matters even more in a game that resolves quickly, which is why the fight for the center in Samok starts from move one. Keep an eye on spots where a row and a diagonal cross. Those become the seeds of double threats later.

Double Threats: Still the Surest Path to a Win

Create two threes in different directions with a single move and your opponent can only block one, so the other becomes four. It's the same principle as Omok's four-three or double-three, just arriving a step earlier, which means you need to start looking for it a step earlier too. A single extended line is easy to shut down at one end, so aim for the intersection where two directions overlap from the start.

Defense: You Need to React Faster Than in Omok

  • Always block immediately anywhere your opponent could complete a four. Same as Omok, this part doesn't change.
  • Here's where it differs: an open three is nearly game over the moment it appears, so you need to contain it back at the open-two stage. Omok's "I can still watch an open three for now" instinct will cost you in Samok.
  • Before playing your own attack, always check first whether your opponent can win on their next move.

Strategy by Skill Level

Just starting out? Focus on building three of your own stones near the center. Winning matters less right now than feeling, firsthand, just how dangerous an open three really is.

Getting comfortable? Build the habit of containing threats at your opponent's open-two stage. Judging "there's still time" with Omok instincts will already be too late here.

Want to go further? Focus on completing your double threat before your opponent does. The Hard AI reads and blocks double threats accurately, so attacking in a single direction rarely works against it.

Omokboard's Connect 4 Board and AI

Omokboard's Connect 4 is played on the same 15×15 board as Omok. The board is wide enough that you rarely get pushed against an edge, so a four can be built almost anywhere. In AI games you play Red and move first, and the AI plays Yellow.

  • Easy looks only one move ahead. It scores each spot for its own attack and for blocking yours, then picks at random from the top five. That's why it sometimes leaves open a spot where you can complete a four next move.
  • Normal reads two moves ahead: its move and your reply. It never misses a spot where it can win right away, and it always blocks a four you could complete next move.
  • Hard reads four moves ahead. As it searches deeper, it keeps only the 12 most promising spots at each step.

It's the same kind of AI as Omok's, but because the goal is one stone shorter, the same four moves reach much further in Connect 4. In Omok, four moves covers roughly the distance from an open three to five in a row. In Connect 4, it reaches all the way from an open two to a finished four. That's why attacks that only push in one direction rarely work against the Hard AI.

That said, Connect 4 on this board heavily favors whoever moves first. When we had the AIs play 20 games, the first player won 19 of the Hard vs Normal games, and playing second, Hard even lost 4 of 10 games to Easy. Since you always move first against the AI, building an accurate double threat is enough to beat Hard. The method and results for every game are in AI Difficulty Benchmarks.

Common Mistakes

  • Chasing your own three and missing the opponent's three or four.
  • Treating an open three lightly out of Omok habit, until it can no longer be stopped.
  • Extending only one direction, leaving a shape that's easy to shut down at either end.

AI Difficulty, Measured

We had Omokboard's AI levels play each other (measured October 18, 2026, alternating who moves first). Each figure is the win rate of the first level against the second, with draws counted as half a win.

MatchupWin rateGames
Hard vs Normal55.0% (11W 9L)20
Normal vs Easy90.0% (18W 2L)20
Hard vs Easy80.0% (16W 4L)20
  • Easy: Random pick from the top 5 one-move scores (defense counts half)
  • Normal: Searches 2 moves ahead
  • Hard: Searches 4 moves ahead (12 candidate spots per step)

In Connect 4, who moves first matters more than difficulty. The first player won 19 of 20 Hard vs Normal games, and moving second Hard won only 1 of 10 against Normal and 6 of 10 against Easy. You always move first against the AI, so an accurate double threat is enough to beat Hard.

Hard spends 82 ms per move on average and 267 ms at most.

For other games and the full method, see AI Difficulty Benchmarks.

FAQ

  • How is this different from classic Connect Four? There's no gravity, so you place freely anywhere on the board.
  • What about five in a row? The game ends the instant four connect, so that point never comes up.
  • Same strategy as Omok? The core idea is the same, but everything moves faster since you only need four. Treat Samok's "open three" as being about as dangerous as Omok's "open four."
  • If I'm good at Omok, am I automatically good at Samok? The instinct for reading threats carries over directly. But Samok demands faster judgment. The "wait and see" approach that works in Omok often costs you here.