Multiplayer chess in the browser, with Stockfish analysis built in
I built FreeChess because every big chess site either wants a subscription or shows ads. Here you open the page and play. No account needed, nothing to pay for. React 19, TypeScript, Vite, Supabase Realtime, and Stockfish running in your browser.
FreeChess is a chess site I built and run on my own. You can play online against other people, against the computer at 20 levels, or pass-and-play on one device. Online games are created from the lobby in a couple of clicks. You play as a guest by default; an account is only there if you want a permanent username and rating.
Moves are checked on the server side, not just in the browser tab. Game state lives in Postgres, moves go through Supabase Edge Functions that validate them with chess.js, and Row-Level Security policies keep players from touching games that are not theirs. Realtime channels carry the moves, chat, draw offers and rematch requests between the two players.
After a game you can review it with Stockfish 19 compiled to WebAssembly, running in a Web Worker in your own browser. It marks blunders and mistakes, shows the best line, and draws the best-move arrow. The same review on Chess.com is limited on the free plan. Here there is no plan.
![]() Live game Clocks, move list, captured pieces, legal-move dots |
![]() Analysis board Eval bar, engine lines, best-move arrow, opening explorer |
- Play in seconds. Pick a time control and you are in a game. Guest play by default, private links for playing a friend.
- Online play on Supabase Realtime: moves, chat, draw offers, takebacks in casual games, rematches, and disconnect detection.
- Stockfish in the browser. Stockfish 19 (WASM) in a Web Worker powers the analysis board, hints, and the full game review with blunder detection.
- Server-checked moves. Edge Functions validate every move with
chess.js; Postgres RLS policies protect the game rows. - Puzzles. Daily puzzle, rated practice sets, and a 5-minute puzzle rush, all generated and verified with the rules engine.
- Works on phones. Responsive layout, seven board themes, piece sets, and synthesized move sounds. No app install.
- Tests. Vitest unit tests plus a Playwright end-to-end suite that plays full games between two browser contexts.
| Component | Technology | Purpose |
|---|---|---|
| Frontend Framework | React 19 | UI |
| Language | TypeScript 5.9 | Types across the app |
| Build Tool | Vite 8 | Dev server and production build |
| Chess Engine | Stockfish WASM & chess.js | Rules, move validation, engine evaluation |
| Backend & Realtime | Supabase | Postgres, Auth, Edge Functions, Realtime |
| Hosting & CI/CD | Netlify & GitHub Actions | Deploys on push to main |
| Testing | Vitest & Playwright | Unit and end-to-end tests |
- Node.js:
>= 20.x - npm:
>= 10.x - Free Supabase account (for self-hosting backend)
-
Clone the repository:
git clone https://github.com/CodeByPartho/chess-multiplayer.git cd chess-multiplayer -
Install dependencies:
npm install
-
Configure environment variables:
cp .env.example .env
Provide your Supabase URL and anonymous public key in
.env:VITE_SUPABASE_URL=https://your-project-id.supabase.co VITE_SUPABASE_ANON_KEY=your-anon-key
-
Start the local development server:
npm run dev
Open
http://localhost:5173in your browser. -
Run test suites:
npm run test # Unit tests via Vitest npm run test:e2e # E2E tests via Playwright
This project is licensed under the MIT License.
Built by Partho

