Docs / Databases & Storage / Neon Serverless Postgres

Neon Serverless Postgres

Serverless PostgreSQL with instant database branching and auto-scaling.

Neon is a serverless PostgreSQL database with compute and storage separated.


Highlights

  • Database Branching: Create isolated database branches matching Git branches. Test schema changes safely on isolated copies without touching production data.
  • Autoscaling & Scale-to-Zero: Compute automatically scales up under load and scales to zero when idle.
  • Postgres Compatibility: Supports standard PostgreSQL extensions (pgvector, uuid-ossp, pg_trgm).
TYPESCRIPT
import { neon } from "@neondatabase/serverless";

const sql = neon(process.env.DATABASE_URL!);

export async function getActiveUsers() {
  return await sql`SELECT id, name, email FROM users WHERE active = true`;
}

Ready to build with AI?

Start building for free with your own keys, or unlock managed compute in seconds