Saturday, October 24, 2026 4,350 lists 78,096 records on file
List your app or device

  1. Home
  2. Database Proxy Software
  3. PgBouncer

PgBouncer

What it is

PgBouncer is a free, self-hosted connection pooler for PostgreSQL. It reuses server connections to reduce the performance impact of opening new ones, with session, transaction, and statement pooling modes. Statement pooling disallows multi-statement transactions. PgBouncer can direct connections to databases on different hosts, but it does not provide internal multi-host load balancing or failover detection. It can track protocol-level prepared statements in transaction and statement pooling when max_prepared_statements is non-zero.

Documented authentication options include client certificates, SCRAM-SHA-256, LDAP, PAM, and HBA-based configuration. Its listed default memory requirement is 2 kB per connection. Building requires Libevent 2.0 or later, pkg-config, and a C11-capable compiler; OpenSSL 1.0.1 or later is required for TLS support. Windows operation is documented, with MinGW as the only supported Windows build environment. Source releases are available, along with pointers to native packages and dedicated RPM and Debian repositories.

For and against

For

  • Supports session, transaction, and statement pooling.
  • Can route to databases on different hosts.
  • Tracks prepared statements in transaction and statement pooling.
  • Documented authentication includes SCRAM-SHA-256 and client certificates.
  • Free, self-hosted software.

Against

  • Statement pooling disallows multi-statement transactions.
  • No internal multi-host load balancing configuration.
  • No internal failover-host configuration or detection.
  • Windows builds require MinGW.

The verdict

PgBouncer provides PostgreSQL connection pooling with several pooling modes and documented authentication options. Teams needing load balancing or failover must arrange those separately.

Who it suits

PgBouncer suits PostgreSQL operators who want to reuse server connections and can manage self-hosted software. It may fit deployments that handle load balancing and failover through DNS or external tools.

Plans and prices

PgBouncer

Free

Source release available · self-hosted software

Every plan, in full

On the record

Authentication
Documented authentication options include client certificates, SCRAM-SHA-256, LDAP, PAM, and HBA-based configuration.pgbouncer.org · read 3 Oct 2026
Backend hosts
PgBouncer can route to destination databases on different hosts and is not tied to one backend server.pgbouncer.org · read 3 Oct 2026
Build dependencies
Building requires Libevent 2.0 or later, pkg-config, and a C11-capable compiler; OpenSSL is needed for TLS support.pgbouncer.org · read 3 Oct 2026
Distribution
The downloads page offers source releases and points to native OS packages and dedicated RPM and Debian package repositories.pgbouncer.org · read 3 Oct 2026
Failover
PgBouncer does not provide internal failover-host configuration or detection; its FAQ describes DNS reconfiguration and external tools as options.pgbouncer.org · read 3 Oct 2026
Integrations
Optional build integrations include PAM, LDAP, and systemd support.pgbouncer.org · read 3 Oct 2026
Load balancing
PgBouncer has no internal multi-host load-balancing configuration; its FAQ describes using DNS round-robin or an external TCP load balancer such as HAProxy or LVS.pgbouncer.org · read 3 Oct 2026
Memory
The features page lists default memory requirements of 2 kB per connection.pgbouncer.org · read 3 Oct 2026
Operating systems
The installation page documents running PgBouncer on Windows and specifies MinGW as its only supported Windows build environment.pgbouncer.org · read 3 Oct 2026
Pooling modes
It supports session, transaction, and statement pooling, with statement pooling disallowing multi-statement transactions.pgbouncer.org · read 3 Oct 2026
Prepared statements
It can track protocol-level prepared statements in transaction and statement pooling when max_prepared_statements is non-zero.pgbouncer.org · read 3 Oct 2026
Purpose
PgBouncer is a PostgreSQL connection pooler that reuses server connections to reduce the performance impact of opening new connections.pgbouncer.org · read 3 Oct 2026
Release and security
The homepage says version 1.26.0, released September 23, 2026, fixes three denial-of-service CVEs.pgbouncer.org · read 3 Oct 2026
TLS
The installation documentation lists OpenSSL 1.0.1 or later as a build dependency for TLS support.pgbouncer.org · read 3 Oct 2026

The review

PgBouncer is a self-hosted connection pooler for PostgreSQL, built for teams that want to reuse database connections and can operate the software themselves. Its three pooling modes make it adaptable to different workloads, but balancing traffic across hosts and handling failover require separate tools.

Overview

PgBouncer focuses on pooling: it reuses server connections to reduce the performance cost of opening new ones. It can route to databases on different hosts, which gives operators flexibility in where a destination lives. It does not choose among hosts for load balancing or detect failed hosts, so environments that need those capabilities must pair it with DNS changes or an external service such as HAProxy or LVS.

The project has been around since 2007 and is distributed as source, with native OS packages and dedicated RPM and Debian repositories also available. Version 1.26.0, released September 23, 2026, fixes three denial-of-service CVEs, making current releases relevant to deployment decisions.

Key features

Pooling modes

Session, transaction, and statement pooling let operators choose how long a backend connection stays associated with a client. Statement pooling is the most restrictive: it disallows multi-statement transactions, so applications that rely on those transactions should use another mode. In transaction and statement modes, PgBouncer can track protocol-level prepared statements when max_prepared_statements is non-zero.

Memory and backend routing

The features page gives a default memory requirement of 2 kB per connection, a useful planning figure for operators sizing a deployment. PgBouncer can target databases hosted on different machines, but that routing flexibility does not add multi-host balancing or failover.

Authentication and TLS

Documented authentication choices include client certificates, SCRAM-SHA-256, LDAP, PAM, and HBA-based configuration. TLS support is available when built with OpenSSL 1.0.1 or later. This range suits teams that need to fit pooling into different authentication setups, while TLS depends on including the required build support.

Pricing

PgBouncer is free. Its PgBouncer plan costs nothing and provides a source release as self-hosted software. There is no paid tier or free trial to weigh; the tradeoff is that teams supply and operate their own deployment rather than receiving a hosted service.

Platforms

PgBouncer supports Linux, Windows, and self-hosted deployment. Building it requires Libevent 2.0 or later, pkg-config, and a C11-capable compiler; OpenSSL is needed for TLS, while PAM, LDAP, and systemd are optional integrations. Windows builds use MinGW, the only supported Windows build environment. These requirements give administrators control over packaging and integrations, but add setup work for teams without build and operations capacity.

Who it's for

PgBouncer is a strong fit for PostgreSQL teams that need connection reuse, want to select among session, transaction, and statement pooling, and are prepared to self-host. It is less suitable for teams that need a built-in multi-host balancing policy, automatic failover, or a managed service.

Pros and cons

  • Pro: Three pooling modes let operators match connection reuse to application behavior.
  • Pro: Broad documented authentication options include certificates, SCRAM-SHA-256, LDAP, PAM, and HBA configuration.
  • Pro: Source releases and several package channels support different installation approaches.
  • Con: Statement pooling rules out multi-statement transactions, limiting its fit for applications that depend on them.
  • Con: Load balancing and failover need DNS changes or external tools, adding operational components for those needs.
  • Con: Self-hosting and build dependencies require teams to manage installation and deployment themselves.

Alternatives

PgCat is another free, self-hosted option for Linux, with an MIT-licensed open-source plan. PgDog fits teams looking for a free open-source option across Linux, macOS, and Windows, with an enterprise plan also offered. ProxySQL is worth considering for Linux self-hosting with a community plan that includes all core features and community support channels; an enterprise plan is also offered.

MySQL is the relevant alternative for readers seeking software centered on SQL and NoSQL applications, with replication and high-availability components. SPQR is an open-source PostgreSQL sharding option for teams whose need is sharding. TurbineProxy offers an open-source Apache-2.0 plan with no per-query fees. Amazon RDS is a paid database service with a free tier, suited to readers considering a database service instead. DBLE provides a GPL-2.0 open-source version, with enterprise support plans available. Browse more options in Database Proxy Software.

Verdict

Choose PgBouncer when your PostgreSQL deployment needs focused connection pooling, you want control over pooling mode and authentication, and your team can self-host it. Its core strength is giving operators three ways to reuse connections at no cost. Look elsewhere or add complementary infrastructure if built-in load balancing, automatic failover, or managed operations are essential.

Alternatives to PgBouncer

Every alternative, ranked