# How to Install Odoo in Debian or Ubuntu

URL: https://sohaib.com/blog/how-to-install-odoo-in-debian-or-ubuntu
Author: Sohaib Khan
Published: May 9, 2019
Updated: Sep 8, 2026
Category: E-commerce Solutions

> Last updated April-15-2022 Once you are logged in, run the following command to update all installed packages to the latest available version apt-get update && apt upgrade 3. Install PostgreSQL server Odoo requires a…

**_Last updated April-15-2022_**

Once you are logged in, run the following command to update all installed packages to the latest available version

```bash
apt-get update && apt upgrade
```

## **3\. Install PostgreSQL server**

Odoo requires a PostgreSQL database to store its information, so we will have to install the PostgreSQL server. We will install a PostgreSQL server using the following command:

```bash
apt-get install postgresql
```

Once installed, start the PostgreSQL server and enable it to start at server boot.

```plaintext
systemctl start postgresql
systemctl enable postgresql
```

## 3\. Add repository and install Odoo

Odoo is not available in the official Ubuntu 16.04 repository, so in order to install it, we will need to add the Odoo repository to the server. In order to do it, run the following commands - **Just add the source list based on the version you are looking to install**

**Odoo 10**

```bash
wget -O - https://nightly.odoo.com/odoo.key | apt-key add - echo "deb http://nightly.odoo.com/10.0/nightly/deb/ ./" >> /etc/apt/sources.list.d/odoo.list
```

**Odoo 11**

```bash
wget -O - https://nightly.odoo.com/odoo.key | apt-key add - echo "deb http://nightly.odoo.com/11.0/nightly/deb/ ./" >> /etc/apt/sources.list.d/odoo.list
```

**Odoo 12**

```bash
wget -O - https://nightly.odoo.com/odoo.key | apt-key add -
echo "deb http://nightly.odoo.com/12.0/nightly/deb/ ./" >> /etc/apt/sources.list.d/odoo.list

Odoo 15
```

```bash
wget -O - https://nightly.odoo.com/odoo.key | apt-key add -
echo "deb http://nightly.odoo.com/15.0/nightly/deb/ ./" >> /etc/apt/sources.list.d/odoo.list
```

## 4\. Install Odoo 10/11/12/15 on Ubuntu

Next, update the local package database

```bash
apt-get update
```

and install Odoo using the apt package manager

```bash
apt-get install odoo
```

This command will install Odoo, Python 3 and all necessary Python modules, create PostgreSQL user and start the Odoo instance. After the installation is completed, you can check the status of the Odoo service:

```plaintext
nano /etc/odoo/odoo.conf
```

Uncomment the ‘admin\_passwrd’ line, and change the admin\_password field with a strong password.

```plaintext
admin_passwd = STRONG_PASSWORD
```

Install wkhtmltopd

```bash
wget https://github.com/wkhtmltopdf/wkhtmltopdf/releases/download/0.12.3/wkhtmltox-0.12.3_linux-generic-amd64.tar.xz
tar vxf wkhtmltox-0.12.3_linux-generic-amd64.tar.xz 
cp wkhtmltox/bin/wk* /usr/local/bin/
```

```plaintext
systemctl restart odoo
```

You might get an error while creating a new database after once you login to http://ip\_:8069, You can solve that by [clicking here](/database-creation-error-new-encoding-utf8-is-incompatible-with-the-encoding-of-the-template-database-sql_ascii-hint-use-the-same-encoding-as-in-the-template-database-or-use-template0-as-templat/)
