What changed since Odoo 19
- Python 3.12 or newer. Odoo 20 will not start on anything older, and warns on versions newer than 3.14. Odoo 19 accepted 3.10.
- PostgreSQL 16 or newer. Odoo 20 warns when it connects to an older server; Odoo 19 asked for 13.
- A choice of PDF engine. wkhtmltopdf is still the default, and Odoo 20 adds an optional engine of its own, Paper Muncher.
- Access rights in one file. Modules declare access in
security/ir.access.csv, one line per group and set of operations with an optional domain, which replaces bothir.model.access.csvand record rules.
Step 1: install Python 3.12
Check what you have with python --version in Command Prompt. On Windows, 3.12 is the safest choice because it is the version Odoo pins its dependencies against. Download the 64-bit Windows installer from python.org.
- Run the installer and choose Customize installation.
- Tick Add python.exe to PATH.
- On Optional Features keep everything selected.
- On Advanced Options tick Install Python 3.12 for all users and Add Python to environment variables, then click Install.
Step 2: install PostgreSQL 16 or newer
Download the PostgreSQL installer for Windows x86-64, version 16 or later, from postgresql.org and run it.
- Keep pgAdmin 4 and the Command Line Tools ticked on Select Components.
- Set a password for the
postgressuperuser and keep it somewhere safe. - Leave the port at
5432and the other settings at their defaults. - You can skip Stack Builder at the end: Odoo needs nothing from it.
Step 3: create the Odoo database user
- Open pgAdmin 4 and set a master password when asked.
- Expand Servers → your PostgreSQL instance → Login/Group Roles.
- Right-click Login/Group Roles → Create → Login/Group Role.
- On General, name the role
odoo20. - On Definition, set a password.
- On Privileges, switch on Can login? and Create databases?, then save.
On your own machine you can also switch on Superuser? to avoid permission errors when restoring backups. Never do that on a server. Odoo refuses to run as the postgres user itself, which is why it gets a role of its own.
Step 4: install the C++ build tools
Most of Odoo’s Python dependencies install from ready-made wheels, but a few still compile native code on Windows. Install Build Tools for Visual Studio from Microsoft with the Desktop development with C++ workload, then restart Windows.
Step 5: install wkhtmltopdf for PDF reports
Odoo 20 prints invoices and reports with wkhtmltopdf by default. Download the Windows 64-bit installer of version 0.12.6 from wkhtmltopdf.org and install it with the defaults, into C:\Program Files\wkhtmltopdf. You will point Odoo at it in Step 8.
Step 6: download the Odoo 20 source
Open the official repository at github.com/odoo/odoo, switch the branch to 20.0, then Code → Download ZIP, and extract it to a folder such as C:\Users\you\odoo-20.0. With Git installed, clone it instead:
git clone https://github.com/odoo/odoo.git --branch 20.0 --depth 1 odoo-20.0With an Odoo Enterprise subscription, get the 20.0 branch of the enterprise repository the same way and keep it next to it, for example in C:\Users\you\enterprise.
Step 7: install PyCharm
| Component | Requirement |
|---|---|
| CPU | x86-64 or ARM64, 4 cores |
| RAM | 8 GB in total, 3 GB free for the IDE |
| Disk | 10 GB |
| Display | 1280 × 720 |
| Windows | 10 or 11 |
Download PyCharm from jetbrains.com and install it with the default options. PyCharm is now one product with a free tier: after the 30-day Pro trial, the free core features are enough for Odoo development.
Step 8: configure the project in PyCharm
Open PyCharm, choose Open, and select the Odoo folder. In its root, create a file named odoo.conf:
[options]
; master password for the database manager
admin_passwd = change-me
db_host = localhost
db_port = 5432
db_user = odoo20
db_password = your_password
addons_path = C:\Users\you\odoo-20.0\addons
; wkhtmltopdf for PDF reports, pg_dump and psql for backups
bin_path = C:\Program Files\wkhtmltopdf\bin
pg_path = C:\Program Files\PostgreSQL\16\bin
http_port = 8020Use the role and password from Step 3, and change the PostgreSQL folder if you installed another version. With Enterprise, list its folder first: addons_path = C:\Users\you\enterprise,C:\Users\you\odoo-20.0\addons. Port 8020 keeps it apart from an Odoo 19 instance on another port.
Next, set the project interpreter (Settings → Project → Python Interpreter → Add Interpreter) to a new virtual environment based on Python 3.12, then install the requirements from PyCharm’s terminal:
pip install -r requirements.txtFinally, create a run configuration: Run → Edit Configurations → + → Python, and fill in:
- Name: Odoo 20
- Script path: the
odoo-binfile in the Odoo folder - Parameters:
-c odoo.conf - Working directory: the Odoo folder
- Interpreter: the virtual environment you set above
Step 9: run Odoo and create a database
Click Run. When the log shows the server is listening, open http://localhost:8020. On the database screen enter the master password from admin_passwd, a database name, the admin email and password, and a language and country. Untick demo data if you want a clean database, then click Create database.
Tips from our developers
- Keep your own modules in a separate folder and add it to
addons_path; never edit Odoo’s core addons. - Install
watchdogin the virtual environment and start Odoo with--dev=all, so Python, view and template changes reload without a restart. - Run a module’s tests on a throwaway database with
-d test20 -i your_module --test-enable; Odoo stops when they finish. - Back up and restore databases from
http://localhost:8020/web/database/manager. That is whatpg_pathis for.
Building modules for a client and short of hands? Hire an Odoo developer from our team in Kuwait.