Skip to content

Getting started

Managed PostgreSQL 15, 16, 17 and 18 with automatic backups, read replicas, connection pooling and no public endpoint.

Overview

Managed PostgreSQL on Granite is the default choice for relational data. Each database is a dedicated PostgreSQL cluster that you never have to install, patch or expose to the internet. Provisioning, updates and routine maintenance are handled by the platform; you get the connection details on the database page and spend your time on the product.

Key Features

  • Your choice of version — PostgreSQL 18, 17, 16 or 15 is selected when the database is created (17 by default). Major-version upgrades of an existing database are temporarily unavailable, so pick the version you plan to stay on.
  • 1 to 3 nodes — start with a single node for development and grow to a 3-node cluster with replication and automatic failover for production. The node configuration can be scaled up and the number of nodes changed after creation.
  • Automatic backups — backups are taken on a schedule and stored in external secure storage, so a problem with the underlying infrastructure never becomes a problem with your data. You can also create a backup manually at any time from the Backups tab and restore any backup into a new database with the same configuration.
  • Point-in-time recovery — restore the database to any moment between the oldest backup and a couple of minutes ago, for example right before an accidental DELETE. See Restoring a database from a backup.
  • Read-only replica — add a dedicated read replica with its own endpoint to offload reporting and analytical queries from the primary. The replica is created, resized and removed from the database page.
  • Connection pooling — create one or more connection pools in front of the database in transaction, session or statement mode, so scaling your application does not exhaust the connection limit.
  • Databases and users — create additional databases and users from the Databases & Users tab and grant each user read-only or full access per database.
  • Insights — CPU, memory, storage and cache hit rate charts on the Insights tab help you notice when it is time to move to a bigger node.
  • Private by default — the database has no public address. It is reachable only from the applications in your project that you explicitly allow.

Connecting

Connection details (host, port, user, password and a ready-to-use DATABASE_URL) are shown on the database page; the read-only replica, when present, has its own endpoint next to them. Pass these values to your application as secrets rather than committing them to the repository.

To reach the database from your laptop, for example to run a migration or open a GUI client, forward the port with the NoVPS CLI (novps port-forward database). The database becomes available on localhost for the duration of the session and nothing is opened up permanently.

Common Use Cases

  • Primary transactional store for web and mobile applications
  • Relational data with strict consistency and complex queries
  • Analytical and reporting queries served from the read-only replica

Client Compatibility

Any standard PostgreSQL client or driver works: psycopg, asyncpg, node-postgres (pg), pgx, JDBC, Npgsql, as well as ORMs such as SQLAlchemy, Prisma, TypeORM, Hibernate and Django’s ORM. When you connect through a pool in transaction mode, avoid session-level features such as prepared statements, SET and advisory locks, or use a session mode pool instead.

For step-by-step instructions on creating a database, see How to create PostgreSQL database.

Read also