---
title: Install PostgreSQL on Linux | Snap Store
description: Get the latest version of PostgreSQL for Linux - The world's most advanced
  open-source relational database.
url: https://snapcraft.io/postgresql
---

# PostgreSQL

[Canonical](https://snapcraft.io/publisher/canonical "View all snaps from Canonical")

* [Canonical](https://snapcraft.io/publisher/canonical "View all snaps from Canonical")
* [Server and Cloud](https://snapcraft.io/search?categories=server-and-cloud)

16/stable 16.15

Install 16/stable of PostgreSQL

---

**Install using the command line**

```
sudo snap install postgresql
```

Don't have snapd? [Get set up for snaps](https://snapcraft.io/docs/installing-snapd).

---

### Package name

* postgresql

---

### License

* Apache-2.0 OR PostgreSQL

---

### Last updated

* 5 October 2026 - 16/stable
* 9 October 2026 - 16/edge

---

### Websites

* [canonical.com](https://canonical.com/data/postgresql "https://canonical.com/data/postgresql")
* [postgresql.org](https://postgresql.org "https://postgresql.org")

---

### Contact

* [matrix.to](https://matrix.to/#/#charmhub-data-platform:ubuntu.com "https://matrix.to/#/#charmhub-data-platform:ubuntu.com")

---

### Source code

* [github.com/canonical/postgresql-snap](https://github.com/canonical/postgresql-snap "https://github.com/canonical/postgresql-snap")
* [github.com/postgres/postgres](https://github.com/postgres/postgres "https://github.com/postgres/postgres")

---

### Command › Alias

* postgresql.clusterdb › clusterdb
* postgresql.createdb › createdb
* postgresql.createlang › createlang
* [Show more](https://snapcraft.io/postgresql "Display more/less aliases")

---

### Report a bug

* [github.com/canonical/postgresql-snap/issues](https://github.com/canonical/postgresql-snap/issues "https://github.com/canonical/postgresql-snap/issues")

---

##### Report a Snap Store violation

* [Report this Snap](https://snapcraft.io/postgresql#report-snap-modal)

---

* [Description](https://snapcraft.io/postgresql#tab-description)
* [Security](https://snapcraft.io/postgresql#tab-security)

#### The world's most advanced open-source relational database.

PostgreSQL is a powerful, open source object-relational database system. It has more than 20 years of active development and a proven architecture that has earned it a strong reputation for reliability, data integrity, and correctness.

**Install the snap**

If you are an Ubuntu user, snapd is pre-installed and ready to go on all recent Ubuntu releases. Simply click on the drop-down menu at the upper right-hand corner of this page, select your channel of choice (e.g. 16/stable), and paste the command in your terminal, e.g.:

`sudo snap install postgresql`

If you are not using Ubuntu, scroll further down this page to find installation instructions for other distributions.

**Use the snap**

Once installed, PostgreSQL will start automatically. To log in, run:

`postgresql.psql -U postgres -h /tmp`

It is highly recommended to set a new password in the `postgres` console:

`\password postgres`

For convenience, the snap alias psql is pre-created:

`psql -U postgres -h /tmp`

**Documentation**

See more PostgreSQL snap documentation on GitHub: <https://github.com/canonical/postgresql-snap/blob/18/edge/docs>

**License and trademark**

The PostgreSQL Snap is free software, distributed under the Apache Software License, version 2.0. It installs, operates and depends on PostgreSQL, which is licensed under the PostgreSQL License, a liberal Open Source license similar to the BSD or MIT licenses.

Postgres, PostgreSQL, Slonik Logo are trademarks or registered trademarks of PGCA. Other trademarks are property of their respective owners. Canonical's PostgreSQL offerings are not sponsored, endorsed, or affiliated with PGCA.

---

## Install PostgreSQL on your Linux distribution

Choose your Linux distribution to get detailed installation instructions. If yours is not shown, get more details on the [installing snapd documentation](https://snapcraft.io/docs/installing-snapd).

[### Arch Linux](https://snapcraft.io/install/postgresql/arch)

[### CentOS](https://snapcraft.io/install/postgresql/centos)

[### Debian](https://snapcraft.io/install/postgresql/debian)

[### elementary OS](https://snapcraft.io/install/postgresql/elementary)

[### Fedora](https://snapcraft.io/install/postgresql/fedora)

[### KDE Neon](https://snapcraft.io/install/postgresql/kde-neon)

[### Kubuntu](https://snapcraft.io/install/postgresql/kubuntu)

[### Manjaro](https://snapcraft.io/install/postgresql/manjaro)

[### Pop!\_OS](https://snapcraft.io/install/postgresql/pop)

[### openSUSE](https://snapcraft.io/install/postgresql/opensuse)

[### Red Hat Enterprise Linux](https://snapcraft.io/install/postgresql/rhel)

[### Ubuntu](https://snapcraft.io/install/postgresql/ubuntu)

[### Raspberry Pi](https://snapcraft.io/install/postgresql/raspbian)
