Developers

Five things on Mistboard can run inside your page, with nothing to install and no API key: a study chapter, a finished game, Mistboard TV, a puzzle, and the analysis board. Each is an iframe. The page inside the frame carries no navigation, no footer, and no sign-in state; it renders the board and nothing else. The study widget is the same one the articles on this site use.

Source code · Contribute · Game data · API · Thank you

This is an iframe, running the snippet below.

Embed a study chapter

Copy this. Swap the two ids for the study and chapter you want, which are the last two segments of the study URL you are reading. The board, the moves, the engine annotations and the branches all come along.

<iframe src="https://mistboard.com/embed/study/ytSzepET/Ue0EgpS7"
        width="760" height="700"
        frameborder="0" loading="lazy"
        style="max-width:100%;border:0"
        title="Every Xiangqi Champion"></iframe>

Embed a game

Any finished game, by its id, which is the last segment of its review URL. The frame shows the final position with the move list beside it; the reader steps through with the buttons, the arrow keys, or by clicking a move. Every variant the site can replay works here, fog games included: a finished fog game is shown from the truth board, exactly as on the review page.

This is an iframe, running the snippet below.
<iframe src="https://mistboard.com/embed/game/xq_a30faae1-a4be-4d58-9cb8-da0659b2c439"
        width="760" height="700"
        style="max-width:100%;border:0"
        frameborder="0" loading="lazy"
        title="A xiangqi game on Mistboard"></iframe>

Add ply=N to open on a particular move instead of the end. A game still in progress is not available to the frame until it finishes.

Embed Mistboard TV

The live board: it follows the featured game in progress and, when there is none, holds the most recently finished one. A game that ends while the reader is watching plays out once and then freezes. Nothing that finished before they arrived ever auto-plays.

This is an iframe, running the snippet below.
<iframe src="https://mistboard.com/embed/tv?channel=xiangqi"
        width="400" height="440"
        style="max-width:100%;border:0"
        frameborder="0" loading="lazy"
        title="Mistboard TV"></iframe>

The snippet follows the xiangqi channel. Set channel= to any of xiangqi, banqi, jieqi, duck-xiangqi, crazyhouse-xiangqi, dark-xiangqi, dark-chess, jungle, jungle-flip, gomoku, engines, or drop it for the cross-variant pick the homepage shows:

https://mistboard.com/embed/tv

Embed the daily puzzle

Today's puzzle, solvable in place: the reader plays the moves on the board, with hints and the solution one click away. Attempts from a frame are never rated. Put a puzzle id after the path to pin one puzzle instead of the daily rotation.

This is an iframe, running the snippet below.
<iframe src="https://mistboard.com/embed/puzzle"
        width="760" height="520"
        style="max-width:100%;border:0"
        frameborder="0" loading="lazy"
        title="Daily xiangqi puzzle"></iframe>

Embed the analysis board

The free xiangqi analysis board: play moves, branch, paste a game or a position. Add fen= to open on a position (underscores may stand in for spaces) and color=black to seat Black at the bottom.

This is an iframe, running the snippet below.
<iframe src="https://mistboard.com/embed/analysis/xiangqi"
        style="width:100%;aspect-ratio:4/3;border:0"
        frameborder="0" loading="lazy"
        title="Xiangqi analysis board"></iframe>
https://mistboard.com/embed/analysis/xiangqi?color=black&fen=4kaR2/4a4/9/9/9/9/9/9/4A4/3AK4_w

One thing the framed board does not have is the engine. The local evaluation runs on WASM threads, which need cross-origin isolation, and a frame is isolated only when the page framing it is too. The engine toggle inside the frame says so rather than half-working. For engine analysis, link to the analysis board itself.

Embed a line of moves

A move list with no game or study behind it, the same card as a chapter: an engine game from a match log, a puzzle's solution, a line from a book. Put the moves in moves= as the variant's own tokens, comma-separated (jungle and banqi squares like a1b1, xiangqi ICCS or UCI), add fen= to start from a position other than the setup, and red=, black=, event= and result= for the card's chrome. ply= opens on a move. The kernel replays the moves; one it refuses ends the line there. Variants: xiangqi, duck-xiangqi, atomic-xiangqi, banqi, jungle and chess.

This is an iframe, running the snippet below.
<iframe src="https://mistboard.com/embed/line/jungle?moves=a1b1%2Ca9a8%2Cb1a1%2Ca7b7%2Ca1b1%2Cg7g6%2Cb1a1%2Ca8a7%2Ca1a2%2Ca7a6%2Ca3b3%2Ca6d6%2Cc3c2%2Cd6d5%2Cb2b1%2Cg9g8%2Cg1f1%2Cg6g5%2Cg3f3%2Cg8g7%2Cf1e1%2Cg7g6%2Ce1e2%2Cg5g4&red=MistyJungle&black=KataGo-AnimalChess&event=Game+67%2C+KataGo-AnimalChess+vs+MistyJungle&result=0-1"
        width="760" height="700"
        style="max-width:100%;border:0"
        frameborder="0" loading="lazy"
        title="A jungle line"></iframe>

Sizing

Give the frame whatever width suits your layout. 320px is the narrowest the board and the move list can share, and anything wider than 1200px stops being a board on a page and starts being the page. The study and game frames keep the height proportional:

Default760 x 700
Narrowest320 x 295
Widest1200 x 1105

The style attribute in the snippet (max-width:100%) is what makes it behave on a phone, so keep it if your layout is fluid. Below about 480px the game frame stacks the move list under the board, so a narrow frame wants to be taller. The TV frame is one board and sits well at 400 by 440; the analysis board wants the width of a column and a 4:3 box.

Background

The frame is transparent. Whatever your page has behind the iframe shows through around the board, so the embed sits on your surface rather than stamping a coloured card onto it. The board and move list sit in one panel of their own, so they stay legible either way.

Theme

By default the embed follows the READER: it renders light or dark to match their system setting, the same as the rest of Mistboard. That is right for a site that also has both themes, and wrong for one that does not, because a light-only page ends up showing a dark board to every dark-mode visitor.

Add theme=light or theme=dark to pin it, on any of the frames. Nothing on your side can do this for you: prefers-color-scheme inside the frame is the browser’s, not your page’s, and a color-scheme property on the iframe element does not reach the document inside it.

https://mistboard.com/embed/study/ytSzepET/Ue0EgpS7?theme=light

Notation

Move labels follow the reader the same way, and run into the same problem: a reader meeting Mistboard for the first time inside your page has no stored preference, so they get the default, which is coordinates. That suits a general visitor and not an article about technique, where the source material is written in WXF or Chinese and a5-a9 is the one form no manual uses.

Add notation=wxf, notation=chinese, notation=algebraic, notation=iccs or notation=coordinate to pin it for your readers. It applies to that frame alone and never writes to their settings, so a reader's own choice on Mistboard is untouched.

https://mistboard.com/embed/study/ytSzepET/Ue0EgpS7?theme=light&notation=wxf

oEmbed

If your platform speaks oEmbed, you do not need any of the above: paste a study or game link into WordPress, Ghost, Discourse or anything else that consumes the standard, and it will resolve the embed on its own. The provider endpoint is:

GET /api/oembed?url=<study, game or embed URL>&maxwidth=<optional>

It accepts the permalink a reader copies (a study chapter, or a game’s review page) as well as the embed path itself, returns a rich type with an html field, and answers only for studies the public can already read and games that have finished. A maxwidth outside the range above is clamped rather than refused. Try it:

https://mistboard.com/api/oembed?url=https%3A%2F%2Fmistboard.com%2Fstudy%2FytSzepET%2FUe0EgpS7

What you can embed

Only what the anonymous public already sees. A private study is a 404 in the frame exactly as it is everywhere else; a game is available once it has finished and never before, so a fog game cannot be framed mid-play; TV shows only games the server already broadcasts. The embed pages are the only ones another site may frame: everything else on Mistboard sends frame-ancestors self.

Embeds are free and need no key. The frame does not run our analytics and never asks who the viewer is, so it issues no credentialed request from your page. It does keep board appearance (piece set, notation) in the viewer's own browser storage, which is why their preferences follow them between embeds. If you are planning something at unusual scale, get in touch first.

HTTP API

The read endpoints behind these pages are public and documented: games, watch feeds, puzzles, studies, the leaderboard, the opening explorer. See the API reference. It is version 0 and may change; the reference says what is stable.

Everything else

Mistboard is AGPL-3.0 and the whole site is on GitHub. If you need something neither the embeds nor the API offer, the contact page is the place to say what for, which is how this page came to exist.