CompareSelf-hosted Postgres
A $24 server is cheapuntil you restore it at 3 a.m.
On a VPS the backups, pooling, upgrades and patches are all yours. BataDB runs them for you, branches your data in one command, and costs $0 while it sleeps.
Side by side
What's in the box.
Every plan gets branching and point-in-time restore, Free included. Your agents get the same CLI and MCP server you do.
| Feature | BataDB | A VPS |
|---|---|---|
| Scale to zero | Yes: After 5 idle minutes | No: Always on |
| Branches with your data | Yes: Copy-on-write, one command | No: Script it yourself |
| No branch fees | Yes: None | Not applicable: No branches to bill |
| Point-in-time restore | Yes: Up to 30 days, included | Partly: WAL archiving you run |
| Connection pooling | Yes: Built in | Partly: Install and tune PgBouncer |
| CLI with JSON output | Yes: --json on every API command | No: SSH |
| MCP server | Yes: 128 tools | Partly: Bring your own |
| One-command import | Yes: bata import | Partly: Dump and restore |
The bill
Watch the idle hours add up.
We priced the same workload on BataDB and on a VPS, then let the month run.
Side project
One small database, busy two hours a day and idle the rest.
- BataDBPay as you go$0.58 a month
- A VPS1 GiB Droplet$6.00 a month
Saved against A VPS, every month
$5.4290% less
Off your plate
The server bill was never the expensive part.
Self-hosting is cheap right up until something breaks. Then it's your weekend. These stop being your job.
Backups
Continuous backups and point-in-time restore, without a WAL archive to babysit.
Pooling
PgBouncer on every project, with nothing to install or tune.
Upgrades and patches
We apply the Postgres updates, so they stop eating your weekends.
Branches
A copy of production for every pull request, in one command.
Move
Moving over takes one command.
bata import copies your database from a VPS into a new BataDB project, then checks row counts and sequences on both sides.
npm install -g @batadata/clibata loginbata import --source "$SOURCE_DATABASE_URL" --name my-app- Point it at the server itself, not a PgBouncer in front of it.
- Open pg_hba.conf and the firewall to the machine running the import.