PostgreSQL ODBC driver for Windows — psqlODBC
psqlODBC is the official ODBC driver for PostgreSQL. It allows Windows applications that use the ODBC API — such as Microsoft Excel, Access, Power BI, Tableau, and ODBC-capable programming languages — to connect to a PostgreSQL database. It is available in both x64 (64-bit) and x86 (32-bit) versions.
x64 vs x86 — which to install?
| Scenario | Install |
|---|---|
| 64-bit applications (Excel 64-bit, Power BI, most modern apps) | psqlODBC x64 |
| 32-bit applications (older Excel, Access 32-bit, legacy apps) | psqlODBC x86 |
| Both 32-bit and 64-bit apps on the same machine | Install both x64 and x86 |
| Unsure which your app uses | Check Task Manager → Details → if app name shows *32, it is 32-bit |
Download and install psqlODBC
- 1
Download from the official source
Get psqlODBC from postgresql.org/ftp/odbc/versions/msi/. Download the latest
psqlodbc_xx_xx_xxxx-x64.zipfor 64-bit orpsqlodbc_xx_xx_xxxx-x86.zipfor 32-bit. - 2
Run the MSI installer
Extract the ZIP and run the MSI file as Administrator. Follow the simple wizard — no configuration is needed during install.
- 3
Open ODBC Data Source Administrator
Press Win+S → search ODBC. Open ODBC Data Sources (64-bit) for x64 or ODBC Data Sources (32-bit) for x86.
- 4
Add a new DSN
Click Add → select PostgreSQL Unicode (or PostgreSQL ANSI for legacy apps) → fill in the connection details:
Data Source: MyPostgresDBDatabase: mydbnameServer: localhost (or server IP)Port: 5432User Name: postgresPassword: your_password - 5
Test the connection
Click Test in the DSN setup dialog. You should see Connection successful. Click Save.
System DSN vs User DSN vs File DSN
| DSN Type | Available to | Use when |
|---|---|---|
| User DSN | Current user only | Personal use, development |
| System DSN | All users and services | Shared apps, Windows services, IIS |
| File DSN | Any machine with the driver | Portable connection, shared configs |
ODBC driver questions
PostgreSQL ODBC driver not showing in ODBC administrator
C:\Windows\System32\odbcad32.exe and the 32-bit one is at C:\Windows\SysWOW64\odbcad32.exe. A 64-bit driver only appears in the 64-bit administrator.Unicode vs ANSI driver — which to use?
Connection test fails with "could not connect to server"
localhost or 127.0.0.1.