Hex
Connect your two shores before your opponent cuts you off.
A rhombus of hexagonal cells: Red connects top and bottom, Blue connects left and right. A game can never end in a draw.
- Players
- 1 or 2 players
- Length
- 5 to 20 min
- Against the AI
- Two players on one device
15 days of full access, no account · No download

How to play
Goal of the game
The board is a rhombus of hexagonal cells. Red tries to connect the red edges (top and bottom) with a continuous chain of its stones; Blue tries to connect the blue edges (left and right). The corner cells belong to both edges.
How it works
- Red starts. Players take turns placing a stone on an empty cell; stones never move.
- Two cells that touch along a side are connected. The first player to connect their two edges wins.
- A game of Hex can never end in a draw: when the board is full, exactly one player has connected their edges.
Pie rule (optional)
The first move gives a big advantage. With the pie rule, after Red’s first stone, Blue may choose to swap: they take that stone as their own (reflected across the diagonal, so that it connects their own edges) and it is then Red’s turn to play. The first player is therefore better off opening with a move that is neither too strong nor too weak.
About the AI
Monte-Carlo tree search (UCT) with RAVE. The simulated games fill the whole board and systematically save attacked bridges, including edge templates. Each candidate move receives prior knowledge drawn from both sides’ shortest paths (the distance left to fill between the edges). At the Master level, the AI simulates several hundred thousand games per move; when victory is secured, it picks the shortest path to finish. With the pie rule, it decides whether to swap by genuinely evaluating the opening.
AI levels
- BeginnerA few hundred simulations and a lot of hesitation: ideal for discovering bridges.
- AmateurKnows bridges but often loses track of the race.
- IntermediateThousands of simulations guided by the shortest paths: solid.
- ExpertTens of thousands of simulations: defends every bridge and cuts at the right moment.
- MasterOver two hundred thousand simulations per move: nearly unbeatable on 7 × 7 and 9 × 9.
