System Requirements
| Component | Version | Notes |
|---|---|---|
| Python | 3.11β3.12 | 3.12 recommended |
| PostgreSQL | 16+ | 17 recommended |
| Node.js | 18+ | Required for asset compilation (Less, SCSS) |
| wkhtmltopdf | 0.12.6 | Required for PDF reports |
| OS | Ubuntu 22.04 / Debian 12 | Recommended; Docker for Windows/macOS |
Ubuntu/Debian Installation
This is the recommended approach for development. Follow these steps in order:
Step 1 β Install system dependencies
sudo apt update && sudo apt upgrade -y
sudo apt install -y python3-pip python3-dev python3-venv \
libxml2-dev libxslt1-dev libldap2-dev libsasl2-dev \
libtiff5-dev libjpeg8-dev libopenjp2-7-dev zlib1g-dev \
libfreetype6-dev liblcms2-dev libwebp-dev libharfbuzz-dev \
libfribidi-dev libxcb1-dev libpq-dev git curl
Step 2 β Install PostgreSQL
sudo apt install -y postgresql postgresql-contrib
sudo systemctl start postgresql
sudo systemctl enable postgresql
# Create Odoo database user (same as your Linux username)
sudo -u postgres createuser -s $USER
Step 3 β Clone Odoo 19
git clone https://github.com/odoo/odoo.git --depth=1 --branch=19.0 ~/odoo19
The --depth=1 flag clones only the latest commit, which is much faster than a full history clone. The --branch=19.0 flag checks out the Odoo 19 branch.
Step 4 β Create virtual environment and install dependencies
python3 -m venv ~/odoo19-venv
source ~/odoo19-venv/bin/activate
pip install -r ~/odoo19/requirements.txt
Step 5 β Create config file
Create ~/odoo19.conf with the following content (replace your_username with your Linux username):
[options]
db_host = localhost
db_port = 5432
db_user = your_username
db_password = False
addons_path = /home/your_username/odoo19/addons,/home/your_username/custom_addons
logfile = /var/log/odoo/odoo.log
Step 6 β Create custom addons directory
mkdir ~/custom_addons
Step 7 β Start Odoo
source ~/odoo19-venv/bin/activate
python ~/odoo19/odoo-bin -c ~/odoo19.conf
# Open http://localhost:8069 in your browser
Docker Setup (Windows / macOS)
If you're on Windows or macOS, Docker is the easiest path to a working Odoo environment. Create a docker-compose.yml file:
# docker-compose.yml
version: '3.8'
services:
db:
image: postgres:16
environment:
POSTGRES_USER: odoo
POSTGRES_PASSWORD: odoo
POSTGRES_DB: postgres
volumes:
- pgdata:/var/lib/postgresql/data
odoo:
image: odoo:19.0
depends_on:
- db
ports:
- "8069:8069"
environment:
HOST: db
USER: odoo
PASSWORD: odoo
volumes:
- odoo-data:/var/lib/odoo
- ./custom_addons:/mnt/extra-addons
volumes:
pgdata:
odoo-data:
mkdir custom_addons
docker-compose up -d
# Open http://localhost:8069 in your browser
The custom_addons directory is mounted into the container at /mnt/extra-addons. Any module you place there will be available in Odoo after updating the app list.
The Docker approach works for running Odoo, but if you want to edit Odoo's source code or run Python tests, WSL2 with Ubuntu gives you a full Linux environment inside Windows. Install Ubuntu from the Microsoft Store, then follow the Ubuntu installation steps above inside WSL2.
VS Code Setup
VS Code is the recommended editor for Odoo development. Install these extensions:
- Python (Microsoft) β core Python language support
- Pylance (Microsoft) β type checking and autocompletion
- XML (Red Hat) β XML formatting and validation
- Odoo Snippets β code snippets for common Odoo patterns
Configure your workspace settings in .vscode/settings.json:
{
"python.defaultInterpreterPath": "~/odoo19-venv/bin/python",
"python.analysis.extraPaths": [
"~/odoo19"
],
"editor.formatOnSave": true,
"[python]": {
"editor.defaultFormatter": "ms-python.black-formatter"
}
}
Tip: Add ~/odoo19 to your VS Code workspace (File β Add Folder to Workspace). This lets Pylance index Odoo's source code, giving you autocompletion for all Odoo models, fields, and methods as you write custom code.
Creating Your First Database
Once Odoo is running at http://localhost:8069, you'll see the database manager page. Fill in the fields:
- Master Password β set a password (it protects database management)
- Database Name β e.g.
odoo_dev - Email β your admin login email
- Password β your admin user password
- Language β select English
- Country β select yours
- Demo Data β check this (useful for learning β gives you sample customers, products, orders)
Click Create database and wait ~2 minutes for initialisation. You'll be redirected to the Odoo main menu β your development environment is ready.
Activating Developer Mode
Developer mode unlocks technical tools that are essential for module development:
- Shows the Technical menu under Settings (access to views, models, actions, sequences, etc.)
- Enables direct view editing from the UI
- Shows field technical names on hover
- Enables the Assets debug mode for frontend debugging
To activate:
- Method 1: Settings β General Settings β scroll to Developer Tools section β click Activate developer mode
- Method 2: Append
?debug=1to any URL, e.g.http://localhost:8069/web?debug=1 - Method 3: Append
?debug=assetsfor full asset debugging (unminified JS)
When developing, always keep developer mode active. Without it, you cannot access the Technical menu, directly inspect views, or see field names β all essential for day-to-day module development.
π Summary
- Odoo 19 requires Python 3.11β3.12, PostgreSQL 16+, Node.js 18+.
- Ubuntu/Debian is the recommended OS for native development β 7 steps from clean OS to running Odoo.
- Docker Compose is the easiest path for Windows/macOS development.
- VS Code with Python + Pylance + XML + Odoo Snippets extensions gives the best development experience.
- Developer mode is essential for module development β activate it via Settings or
?debug=1in the URL. - Your
custom_addonsdirectory is where all your custom modules will live.
FAQ
Native Windows is not recommended β wkhtmltopdf and some Python C-extension dependencies have issues on Windows. Two alternatives work well: Docker on Windows (good for running Odoo, limited for editing source), or WSL2 with Ubuntu (the best Windows option β gives you a full Linux environment with proper Python compilation, full Odoo source access, and VS Code Remote development). Install WSL2, install Ubuntu from the Microsoft Store, then follow the Ubuntu installation steps above.
The master password is a server-level password that protects database management operations (creating, dropping, duplicating databases). It is set in odoo.conf as the admin_passwd option. It is completely separate from any Odoo user account password. For local development, you can set it to something simple like admin.
Odoo's web interface runs on port 8069 by default. The long-polling server (used for live chat, bus notifications, and real-time features) runs on port 8072 by default. Both can be changed in odoo.conf via the xmlrpc_port and longpolling_port options.
Python method changes take effect after a server restart β Odoo is a Python process; it doesn't hot-reload Python code. For changes that affect the database schema (new fields, new models) or data (new views, menus, security records), you also need to upgrade the module. You can do this by restarting with -u module_name, e.g. python odoo-bin -c ~/odoo19.conf -u my_custom_module. In developer mode, you can also upgrade from Settings β Technical β Installed Modules.