Skip to main content
By default, anyone with a database’s host, port and password can connect to it. That’s convenient while you build, and it’s how most apps on Pxxl reach their database. For production, you can narrow it down: allow only certain IP addresses, rotate the password, and move the database to a team. All of this is in the database’s Settings > Networking and Settings > Ownership.

Allowed IPs

An allowlist makes the database refuse connections from every address that isn’t on it, even with the right password.
The Allowed IPs card in a database's Networking settings, with an Addresses box and the Allow apps on Pxxl switch turned on.
1

Open Networking

Open the database, select Settings, then Networking.
2

Add addresses

In Addresses, put one IPv4 address, IPv6 address or CIDR range per line, for example 203.0.113.7 or 198.51.100.0/24. Add my IP adds the address you’re browsing from.
3

Decide about apps on Pxxl

Keep Allow apps on Pxxl on if your Pxxl projects use this database. See below.
4

Save

Choose Save access. The new list applies to new connections straight away.

Allow apps on Pxxl

Your projects on Pxxl connect from Pxxl’s servers, not from a fixed address of your own. Allow apps on Pxxl adds those servers’ addresses, and the static outbound IP, to your list for you. It’s on by default. Those addresses are shared by every app on Pxxl, so with it on, the password is still what keeps other workloads out. Turn it off if only outside systems connect to this database, such as an app hosted elsewhere or your office network.

From the API

Reset the password

Under Settings > Networking > Reset password, type a new password of at least 12 characters, or choose Generate, then Change password. Every app or tool still using the old password stops connecting at once. Update DATABASE_URL in your projects (or the Vault secret they reference) and redeploy.

Require SSL

The Require SSL switch is shown for MySQL only, and managed SSL enforcement isn’t available yet for any engine. See encryption in transit.

Transfer ownership

Settings > Ownership transfers the database to another owner, such as a team. Check the new owner’s plan has room for another database first.

Where to go next

Connect to a database

URL formats and code examples.

Backups

Keep restorable copies of your data.