Odoo Website Module
Nine Men's Morris
The 3,000-year-old strategy game, playing perfectly, inside Odoo.
A fully playable Nine Men's Morris board built natively into your Odoo website, with an optional AI opponent that never plays a sub-optimal move.
Get Nine Men's MorrisHow It Works
Open source · LGPL-3 · Odoo 19
A game built into your website
One of the oldest games, played the modern way.
Nine Men's Morris adds a dedicated /nine-mens-morris/game_page
page to your Odoo website, letting visitors play a full game of
Nine Men's Morris without leaving your site or installing anything.
Simple for visitors. Native to Odoo.
The board runs directly in your Odoo website frontend using Odoo's OWL framework. Placing, sliding and removing pieces all happen interactively, without traditional page reloads.
There are no external embeds or third-party game widgets involved on the frontend. Install the module, publish your website, and your Nine Men's Morris board is ready to go.
The optional AI opponent runs on a separate, self-hosted backend service, so your Odoo instance stays free of the heavy lifting involved in solving the game.
The rules, refreshed
Three phases, one board.
Nine Men's Morris (also known as Mills or Muehle) is played across three distinct phases, and this module walks visitors through all of them automatically as the game progresses.
1. Placing Phase
Each player takes turns placing their 9 pieces on empty points of the board. Lining up three pieces in a row forms a mill, letting you remove one of your opponent's pieces from the board.
2. Moving Phase
Once all 18 pieces are on the board, players slide a piece along a connecting line to an adjacent empty point, aiming to form new mills or block their opponent's.
3. Flying Phase
When a player is reduced to just 3 pieces, the movement restriction lifts: their pieces can "fly" to any empty point on the board, not just adjacent ones.
A player loses once they're reduced to fewer than 3 pieces, or once they have no legal move left to make. The board itself is the classic three-concentric-squares layout, connected by lines at the midpoints, giving 24 points in total.
An opponent that never misplays
Powered by a fully solved game.
Nine Men's Morris was mathematically solved in 1993: with perfect play from both sides, the game is a draw. This module's AI backend uses that same principle, drawing on a precalculated database of positions to work out the objectively best move from any board state.
Rather than searching moves in real time, the backend looks the current position up and returns every possible move along with the strongest one, so the AI never plays a losing move once it has a chance to avoid it.
- Precalculated move database, not live search
- Built on the open-source Muehle engine by Thomas Weber
- Runs as a separate, self-hosted C++ service
- Odoo sends the board state, the API returns the best move
Two parts, one experience
How the pieces fit together.
The project is split into a lightweight Odoo module and a standalone AI backend, so each part can be updated, rehosted or scaled independently.
Odoo module (frontend)
Built with Odoo's OWL component framework, this is what visitors interact with: the board, the pieces, phase detection and mill validation, all rendered natively inside your website.
AI backend (API)
A separate C++ service that hosts the precalculated move database. Odoo talks to it over a simple HTTP endpoint, sending the current board and receiving the best move in response.
Who is it for?
A small game with a serious opponent.
Nine Men's Morris suits anyone who wants to add a genuine, skill-testing game to their Odoo website, not just a time-waster.
Website owners
Add an interactive game with real depth, backed by an opponent that plays as close to perfectly as possible.
Board game fans
Try to hold a draw against an AI built on a fully solved version of the game, no easy wins here.
Odoo developers
A worked example of pairing an OWL frontend with an external, self-hosted API service.
Get Nine Men's Morris
Add it to your Odoo website.
Nine Men's Morris is free and open source, released under the LGPL-3 licence, with the AI backend released under MIT.
Get the Odoo Module Get the AI Backend
Odoo 19 · Odoo Website · OWL · Full setup and API docs coming soon