How to Install Odoo on Windows
A Comprehensive Guide of installation of Odoo on Windows
Odoo is a powerful open-source ERP system that offers a wide range of business management tools. While it is commonly used in Linux environments, installing Odoo on Windows is a practical solution for users who prefer the familiarity of Windows. This guide will walk you through the step-by-step process of installing Odoo 17 on Windows, enabling you to take full advantage of this versatile platform.
Why Install Odoo on Windows?
While Linux is often the go-to choice for hosting Odoo due to its stability and performance, many users are more comfortable with Windows. Installing Odoo on Windows allows businesses to benefit from its robust features without requiring a Linux setup, making it more accessible to a wider audience.
Step-by-Step Installation Guide
1. Install Python
Before starting, check if Python is already installed on your system. Open the Command Prompt and type:
python --version
If Python is not installed or the version is below 3.10, download and install the latest version of Python from Python’s official website. During installation, select the Custom Installation option and check the “Add Python to PATH” box.
2. Install PostgreSQL
PostgreSQL is the database system used by Odoo. Download PostgreSQL (version 13 or later) from the official website.
During installation:
- Check all components on the “Select Components” page.
- Set a superuser password and note it down for later.
- After installation, complete the Stack Builder wizard to add database drivers.
3. Configure pgAdmin and PSQL
pgAdmin is a GUI tool for managing PostgreSQL databases. Open pgAdmin, log in with your superuser password, and:
- Expand the “Servers” option in the Object Explorer.
- Create a new role under “Login/Group Roles.”
- Set a name, password, and privileges for the new role.
4. Install the C++ Build Tools
Odoo requires C++ build tools for some dependencies. Download the installer from Microsoft’s website and install the “Desktop Development with C++” workload. Restart your system once the installation is complete.
5. Download Odoo 17
Visit Odoo’s GitHub repository and search for the Odoo project. Ensure you select the branch for version 17. Download the ZIP file, extract it, and save it in a safe location.
6. Install PyCharm or VS Code
PyCharm or VS Code is an IDE that simplifies Python development. Download the community edition from JetBrains. Follow the installation steps and ensure your system meets the minimum requirements (e.g., 4GB RAM, modern CPU).
7. Set Up the Development Environment in PyCharm
- Open PyCharm and select Open Existing Project.
- Navigate to the extracted Odoo 17 folder and open it.
- Create an
odoo.conf
file inside the project folder with the following content:
[options]
admin_passwd = admin
db_host = localhost
db_port = 5432
db_user = <your_pg_user>
db_password = <your_pg_password>
addons_path = <path_to_odoo_addons>
xmlrpc_port = 8017
Replace <your_pg_user>
, <your_pg_password>
, and <path_to_odoo_addons>
with your PostgreSQL username, password, and the addons folder path, respectively.
4. Configure the Python interpreter in PyCharm by navigating to Settings > Project Settings > Python Interpreter. Add the system interpreter and ensure it points to the installed Python version.
or create a virtual environment using below command
pip install virtualenv
python<version> -m venv <virtual-environment-name>
Like So 👇
mkdir projectA
cd projectA
python3.8 -m venv env
5. Create a run configuration for Odoo by selecting Edit Configurations, clicking the + icon, and choosing Python Interpreter. Set the script path to odoo-bin
and save the configuration.
and on the script parameter
-c <path of odoo.conf>
On the VS Code
after activating the virtual environment using
source env/bin/activate
After Activating the Virtual Environment whether Via Pycharm or VS Code Install the Packages
pip install -r requirements.txt
To run Odoo write command in your terminal
./odoo-bin -c <path of odoo.conf>
Missing package Alternate package for install
pip install psycopg2
pip install psycopg2-binary
pip install pillow
pip install PIL-Tools
pip install dateutils
pip install infi.win32service
pip install pypiwin32
After adding the missing packages, run the instance once again open the browser and paste the “localhost:8017” address.
Wrapping Up
By following these steps, you’ll have Odoo 17 installed and running on your Windows system. This setup allows you to develop, test, and use Odoo without relying on a Linux environment, offering convenience and flexibility. Whether you’re a developer or a business owner, installing Odoo on Windows opens up a world of possibilities for managing your operations effectively.
Got any questions or need further assistance? Drop a comment below or reach out to us!