What is the palace in xiangqi?
These answers restate the rules implemented by our open-source engine, which follows the WXF laws and is regression-tested against the official 110-diagram repetition casebook. Where an answer refers to a specific position, that position lives on the linked reference page, where the build verifies it against the engine before publishing.
Direct answer
The palace (九宮) is the 3×3 box of nine points at each end of the board, marked with an X. The general and both advisors may never leave it. Because the general is confined for the whole game, you always know exactly where the target is — which is the single biggest structural difference from chess.
What the diagonals mean
The drawn diagonals show the advisor's moves, which are one point diagonally. The general does not use them: it moves one point orthogonally only, along the straight lines.
So an advisor reaches five of the nine points (the four corners and the centre) and the general reaches all nine.
Why it changes how you attack
There is no castling and nowhere to run. An attack is therefore a counting exercise rather than a vague build-up: you are covering specific points out of nine, and you can literally count whether you have enough attackers.
It also means the defender's own advisors can block the general's escape squares, which is exactly how several standard mates work.
Related questions
Can any other piece enter the palace?
Yes — enemy and friendly pieces of every type may move through and stand in it. Only the general and advisors are restricted from leaving.
Can a horse enter the palace?
Yes, freely, subject only to its usual blocked-leg rule.