# How to connect Power BI to Odoo

> Source: https://netray.co/integrations/odoo-power-bi
> Publisher: Netray (netray.co), AI and integration engineering for ERP and manufacturing systems.
> Section: Integrations

## Short answer

Connect Power BI to Odoo through a read-only PostgreSQL connection if you self-host, through the external API or an export for hosted editions, or best through a small data warehouse that flattens Odoo's tables. Use the on-premises data gateway for refreshes, and model a few core manufacturing dashboards first.

## System

Odoo

## Capability

power-bi

## Intro

Odoo has its own reporting, pivot views, dashboards and spreadsheet features, and for many teams those are enough. Power BI enters when you want to combine Odoo with other sources, share governed datasets across the company, or build visuals Odoo's views do not offer.

How you connect depends on where Odoo runs. A self-hosted Odoo gives you PostgreSQL access. Odoo.sh offers more limited access depending on setup, and Odoo Online does not give database access at all, so you would use the API or exports.

The harder part is the data model. Odoo's tables are normalised and full of many2one links and translated fields, so a semantic layer or warehouse step usually pays off.

## Use Cases

### Production performance

**Description:** Planned versus actual dates and quantities from mrp.production and mrp.workorder, with scrap and duration by work center.

### On-time delivery

**Description:** Promised versus shipped dates from sale.order and stock.picking, by customer and product family.

### Inventory health

**Description:** Stock value, turns and ageing from stock.quant and stock valuation data, by warehouse and location.

### Supplier scorecards

**Description:** Receipt timeliness and price variance from purchase.order.line and stock moves, by vendor.

### Margin by job or product

**Description:** Combine sales, manufacturing cost and accounting (account.move.line) for profitability views that finance trusts.

### Multi-company roll-up

**Description:** Combine several Odoo companies or databases with other systems into one governed dataset.

## System Surface

- PostgreSQL: Odoo stores everything in one database; Power BI's PostgreSQL connector can read it on self-hosted installs with a read-only role, ideally against a replica.
- External API (XML-RPC or JSON-RPC) for hosted editions; slower for bulk data, so use incremental pulls by write_date into a warehouse.
- Odoo exports (CSV or XLSX from list views) for one-off analysis, and scheduled actions that write files for batch loads.
- Table naming follows model names with dots replaced by underscores, such as mrp_production and stock_quant. Translated fields and some values are stored as JSON in recent versions, so check how your version stores names.
- Odoo's own Dashboards and Spreadsheet features in Enterprise can cover simple reporting without leaving Odoo.

## How It Works

### Decide the data route

**Detail:** Direct PostgreSQL for small self-hosted setups, replica or warehouse for larger ones, API pulls for hosted editions.

### Create a read-only access path

**Detail:** A PostgreSQL role with select on needed tables, ideally on a streaming replica so reports do not slow down users.

### Set up the on-premises data gateway

**Detail:** Install it on a server that can reach the database, register it with the Power BI service and configure the data source for scheduled refresh.

### Build a clean model

**Detail:** Create views or a warehouse layer that resolves many2one names, flattens translations, filters by company and adds date tables.

### Build three dashboards first

**Detail:** Production performance, on-time delivery and inventory health. Agree on definitions with the business before styling.

### Add row-level security

**Detail:** Mirror important access rules, such as company or sales team, using Power BI roles because Odoo record rules do not travel with the data.

### Add natural-language Q&A

**Detail:** Use Power BI's Q&A or Copilot features where licensed, or a private assistant that answers from the same semantic model.

## Example Flows

### Nightly refresh from a replica

**Trigger:** Scheduled refresh at 02:00 in the Power BI service.

**Steps:**

- The gateway connects to the PostgreSQL replica with the read-only role.
- Power BI queries curated views such as v_mo_performance and v_otd.
- Incremental refresh loads only rows changed since the last run, based on write_date.
- Dashboards update before the morning production meeting.

**Result:** Fresh numbers without adding load to the live database.

### Hosted Odoo via API to warehouse

**Trigger:** A nightly job in Azure or a local server pulls changed records.

**Steps:**

- Job authenticates with an API key and reads changed records by write_date.
- It upserts them into a warehouse database.
- Power BI connects to the warehouse, not to Odoo.
- Deleted records are handled with a periodic reconciliation.

**Result:** Reporting works even where there is no database access.

## On Prem

A self-hosted Odoo fits Power BI Desktop and the Power BI service through the on-premises data gateway, which keeps the database inside your network and only sends query results outward. If the reports themselves must stay inside, consider Power BI Report Server, which is a separate licensed product. For natural-language questions on private data, run an open-weight model locally over a semantic layer or SQL views, so questions and results never leave the building. Keep the replica or warehouse read-only and firewall it from the internet.

## Security

- Use a dedicated read-only PostgreSQL role, restricted to the needed views.
- Prefer a replica or warehouse over querying the production database directly.
- Implement row-level security in Power BI to reflect company and team access.
- Restrict workspace access and avoid exporting detailed data to personal files.
- Secure the gateway host and keep its credentials in managed storage.

## Options

### Odoo's built-in pivot, graph and dashboard views

**Fit:** Single-company reporting with standard questions. Enough if you do not need cross-system data.

**Effort:** Hours to days inside Odoo.

### Direct PostgreSQL with the gateway

**Fit:** Self-hosted Odoo with a BI developer who understands the schema.

**Effort:** Days for first reports, more for a maintainable model.

### Warehouse plus Power BI via a partner such as Netray

**Fit:** Multiple sources, governed definitions and optional private natural-language Q&A.

**Effort:** A scoped project of several weeks for the first dashboards and model.

## Pitfalls

- Querying production tables directly in DirectQuery during working hours and slowing Odoo.
- Reading raw tables and forgetting to filter by company or active flag.
- Different definitions of on-time delivery across departments.
- Ignoring translated and JSON-stored fields, leading to unreadable names.
- Skipping row-level security because Odoo's record rules do not carry over.

## Faq

### Does Power BI have a native Odoo connector?

**Answer:** Not as a standard built-in connector as far as I know. Common routes are the PostgreSQL connector for self-hosted Odoo, a warehouse, or third-party connectors. Check the current Power BI connector list for your region and licence.

### Can I connect to Odoo Online?

**Answer:** Not through the database, since Odoo Online does not expose it. Use exports or the external API if your plan allows it, ideally loading into a warehouse that Power BI reads.

### Do I need the data gateway?

**Answer:** Yes for scheduled refresh from an on-premises database to the Power BI service. Import-only use in Power BI Desktop does not need it, but cannot refresh automatically in the cloud.

### Import or DirectQuery?

**Answer:** Import with incremental refresh is usually the safer choice for Odoo, as it limits load on the live system. DirectQuery can be useful for small, well-indexed views but can be slow and heavy on busy databases.

### Can I ask questions in plain English?

**Answer:** Yes if you invest in a clean semantic model. Power BI offers Q&A and Copilot features depending on licence, and a private assistant can query the same views on-prem if data must not leave.

## Search terms

odoo power bi, connect power bi to odoo, odoo power bi integration, odoo postgresql power bi, odoo reporting power bi, power bi odoo manufacturing dashboard, odoo data gateway power bi, odoo power bi connector, odoo bi on premise

---
Talk to an engineer: https://netray.co/contact?intent=erp_ai | Machine catalog: https://netray.co/agent/catalog.json
