Add chess to your website
A free, playable chess board for any site: classic chess and Chess960, against the computer or a friend by link and QR code. No sign-up for you or your visitors, no API keys, no approval.
Set it up
1. Choose what the widget offers
2. Choose how it looks
3. Copy the code and paste it into your page
Recommended: iframe (works in any CMS)
One line of JavaScript (the board adjusts its height)
What your visitors get
- A board that appears instantly and answers moves; the engine runs in the visitor's browser.
- Games with a friend by link, QR code or the phone's share menu — the friend opens the link and plays.
- Correct Chess960 castling and a numbered starting position (0–959).
- No ads, no pop-ups, no redirects; only a small “Powered by CH960” link under the board.
Works with any site
- WordPress: add a “Custom HTML” block and paste the iframe code.
- Wix: Add → Embed code → Embed HTML, paste the code.
- Squarespace: add a Code block and paste the code.
- Webflow: add an Embed element and paste the code.
- React, Vue, Next.js: render the iframe as a normal element — nothing to install.
JavaScript API and events
For sites that want to react to games — for example, to send them to their own analytics:
<div id="ch960-widget"></div>
<script src="https://ch960.com/widget.js"></script>
<script>
var widget = CH960Widget.create({
element: "#ch960-widget",
variant: "all", // all | classic | chess960
opponent: "all", // all | computer | friend
theme: "auto", // auto | light | dark
language: "auto", // auto | en | ru | th | es | de | fr | …
engineLevel: 3 // 1–5
});
widget.on("game_started", function (e) { console.log(e.variant, e.opponent); });
widget.on("game_finished", function (e) { console.log(e.result); });
widget.on("friend_invited", function (e) { console.log(e.url); });
widget.on("variant_changed", function (e) { console.log(e.variant); });
</script>
Privacy and safety
The widget runs in an isolated iframe, so it cannot change your page. It loads no third-party trackers; visitors play as anonymous guests. A game with a friend stores only the moves on CH960, under the same rules as on ch960.com (see the privacy policy).