Forum Discussion
Configure Gateway to connect to PostgreSQL
- 3 months ago
Hi korayg,
Since the PostgreSQL connection works in Power BI Desktop, the database server and credentials are likely correct. The problem may be related to the Gateway configuration. Please check the Gateway version, as older versions might need the Npgsql provider installed separately, and make sure the authentication settings are the same as in Power BI Desktop. Also, confirm if the Gateway is installed on the same machine as Power BI Desktop, since the Gateway must be able to access the PostgreSQL server and meet any network, firewall, or SSL requirements.
Power Query PostgreSQL connector - Power Query | Microsoft Learn
On-premises data gateway - Power BI | Microsoft Learn
Thank you.
Hi korayg ,
Power BI Desktop connects directly to PostgreSQL because it runs locally on your machine. In the Service, though, you’re trying to reach an on‑premises PostgreSQL database, which requires the On‑premises Data Gateway as a bridge. The gateway must be installed on a server that has network access to your PostgreSQL instance, and the 64‑bit Npgsql driver needs to be installed on that gateway machine. Once the driver is in place and the gateway is configured, you can add the PostgreSQL data source under Manage Connections & Gateways and the Service will connect successfully.
Thanks,
Sai Teja