PlayNook

Board Game · Chess Variant

Play Xiangqi Online — Chinese Chess, Free

Nine files, ten ranks, a river down the middle. The cannon needs a piece to jump before it can capture, the elephant can be blocked by a single stone two points away, and having no legal move at all is a loss here — not a draw.

Nine files, ten ranks, a river down the middle, a palace behind each back rank. Xiangqi looks like chess from across the room and plays like something else entirely once the cannon enters the picture.

How to play Xiangqi

Pieces sit on the intersections, not in the squares between them — the same convention as go, not the square-filling convention of Western chess or checkers. Checkmate the enemy general to win.

How each piece moves

  • General — one step orthogonally, confined to the palace.
  • Advisor — one step diagonally, confined to the palace.
  • Elephant — exactly two points diagonally, never crossing the river, blocked if the midpoint is occupied by anything — friend or foe. This point has a name: the elephant's eye.
  • Horse — one step orthogonally then one diagonally outward, blocked ("hobbled") if the orthogonal point in between is occupied.
  • Chariot — any distance orthogonally, blocked by the first piece in its path. The strongest piece on the board.
  • Cannon — moves like the chariot when not capturing. To capture, it must jump over exactly one piece and land on an enemy piece beyond it.
  • Soldier — one step forward only, until it crosses the river; after that, forward or sideways, never backward.

The flying general rule

The two generals may never face each other on a completely open file. A move that would create that position is illegal — including a move by some other piece that happens to clear the file between them, not just a move by the general itself. We built this as a direct check in the engine rather than a special case: after every candidate move, if the two generals would see each other with nothing in between, that move is rejected, the same way a move leaving your own general in check is rejected.

How do you win at Xiangqi?

Checkmate the enemy general — leave them in check with no legal way out. Having no legal move at all is also a loss here, even without being in check, which is the reverse of Western chess, where that same position is a draw.

Why the cannon is the trickiest piece to learn

A red cannon, a black soldier acting as a screen, and a black horse two squares further along the same line, with a green ring around the horse showing it can be captured by jumping the screen
One screen, any colour, and the cannon captures whatever sits directly beyond it — nothing else about its aim matters.

The cannon is really two pieces sharing one name. Moving quietly, it slides in a straight line and cannot jump anything, exactly like the chariot. Capturing, it must jump exactly one piece — its own colour or the enemy's, it makes no difference — and land on an enemy piece immediately beyond that single screen. No screen, or two, or more, and there is no capture in that direction at all.

New players consistently expect it to behave like the chariot all the time. We tested the boundary cases specifically before shipping this page: a clear path with no screen produces no captures, a path with exactly one piece in the way produces exactly the capture you'd expect, and landing on the screen itself is never legal.

What makes Xiangqi different from Western chess

The board itself is the biggest difference: pieces occupy intersections on a 9×10 grid rather than squares on an 8×8 one, and the river and palace restrict four of the seven piece types to only part of the board. There is no castling, no piece promotion, and no two-square opening move for soldiers — every piece moves the same way from the first move of the game to the last.

Is a draw possible in Xiangqi?

Rarely, and never simply by running out of moves — that is a loss here, not a draw. The one route to a genuine draw on this page is threefold repetition. Real Xiangqi tournament rules go considerably further, prohibiting perpetual checks and perpetual chases of an undefended piece in ways that plain repetition does not capture — but those rules have enough contested edge cases that even human arbiters argue about them, so this page uses the simpler repetition rule rather than risk getting a genuinely disputed case wrong.

Playing Xiangqi against the computer

How do the three computer levels differ?

In how many candidate moves get a second look at the reply and how often a merely good move gets played instead of insisting on the exact best one — the same design as the other computer opponents on this site, including Reversi and Halma. The evaluation itself uses standard approximate piece values: chariot 9, cannon 4.5, horse 4, advisor 2, elephant 2, and a soldier worth roughly double once it has crossed the river and gained the ability to move sideways as well as forward.

Where Xiangqi comes from

China, further back than any single date can honestly claim. Chess-like games appear in Chinese writing from well over a thousand years ago, but the version with a river, a palace and a cannon — recognisably today's Xiangqi — is generally placed around the Song dynasty, roughly a thousand years back, with the rules settling into close to their modern form over the centuries that followed.

The cannon's name is older than it looks: 炮/砲 originally meant a siege catapult, not a gunpowder weapon. The piece and its name likely predate the military use of actual gunpowder cannons in China by some distance — a reminder that the piece was named for what armies already had, not for what came later.

If you like this one

  • Chess — no river, no palace, but the same goal: corner the enemy king
  • Checkers — forced diagonal captures on a much simpler board
  • Reversi — the computer opponent here shares its candidate-scoring approach
  • Halma — jumping without capturing, the opposite instinct from the cannon

Frequently asked questions

+ How do you play Xiangqi?

Nine files, ten ranks, pieces sitting on the intersections rather than in squares — the same convention as go. A river runs between rank 5 and rank 6, and each side has a 3x3 palace directly behind their own back rank. Each piece type moves its own way; the general and advisor never leave the palace, the elephant never crosses the river, and the cannon needs to jump exactly one piece to capture anything. Checkmate the enemy general to win.

+ How does each piece move in Xiangqi?

General: one step orthogonally, palace only. Advisor: one step diagonally, palace only. Elephant: exactly two points diagonally, own half of the board only, blocked if the midpoint — the 'elephant's eye' — is occupied by anything at all. Horse: one step orthogonally then one diagonally outward, blocked ('hobbled') if the orthogonal point in between is occupied. Chariot: any distance orthogonally, like a rook. Cannon: moves like the chariot when not capturing, but to capture it must jump over exactly one piece, friend or foe, and land on an enemy piece beyond it. Soldier: one step forward only until it crosses the river, then forward or sideways — never backward, ever.

+ What is the flying general rule?

The two generals may never end up facing each other on a completely open file. A move that would create that position — even a move by some third piece that happens to clear the file between them — is simply illegal, exactly like a move that leaves your own general in check. We tested this specifically: a chariot sitting between the two generals cannot step sideways, only up or down the same file, in our own engine checks.

+ Is a draw possible in Xiangqi?

Rarely, and never by running out of moves. Having no legal move at all is a loss for the player stuck with it — the opposite of Western chess, where that same position is a draw. The one route to a draw here is repetition: the same position occurring three times, which this page treats as a draw. Xiangqi's own tournament rules govern repeated checks and repeated chases far more strictly than plain repetition, but those rules are genuinely intricate — even human arbiters argue edge cases — so this page simplifies to the plainer rule rather than get an edge case wrong.

+ Why is the cannon the hardest piece to learn?

Because it is two different pieces depending on what it is doing. Moving quietly, it slides like a chariot and cannot jump anything. Capturing, it must jump exactly one piece — any piece, its own colour or the enemy's — and land on an enemy piece immediately beyond that single screen. Zero screens or two or more in the way, and there is no capture in that direction at all. New players consistently expect it to work like the chariot; it only does half the time.

+ How do the three computer levels differ?

In how many candidate moves get a second look at the reply and how often a merely good move gets played instead of insisting on the exact best one — the same approach used across the other computer opponents on this site. The evaluation itself uses the piece values most Xiangqi engines settle on: chariot 9, cannon 4.5, horse 4, advisor 2, elephant 2, and a soldier worth roughly double once it has crossed the river and gained the ability to move sideways.

+ Can I play Xiangqi with a friend online?

Yes. Choose 'With a friend online' below the board and press Open a table. You get a four-character code; send it to your friend, they type it in and press Join. There is a chat window built in, and neither of you needs an account or a download.

+ Where does Xiangqi come from?

China, and further back than any single date can honestly claim. Chess-like games are referenced in Chinese writing from centuries earlier, but the version with a river, a palace and a cannon — recognisably today's Xiangqi — is generally placed around the Song dynasty, roughly a thousand years ago. The cannon's name comes from siege catapults, not gunpowder artillery; the character predates gunpowder's military use in China by a long way.

+ Is it free?

Yes, and there is no sign-up, for the online tables either. Nothing about a solo or hotseat game is saved anywhere; close the tab and start fresh next time.

More games like this