PocketBase: Self-Hosted Backend in a Single File
PocketBase is an open-source real-time backend with 56,000+ GitHub stars. Get a database, auth, file storage, and admin UI in a single executable on your VPS.
PocketBase: Self-Hosted Backend in a Single File
PocketBase is an open-source backend that packages a real-time database, authentication, file storage, and an admin dashboard into a single executable file. With over 56,000 GitHub stars, it has become the go-to choice for developers who want a complete backend without managing multiple services. Written in Go with an embedded SQLite database, PocketBase starts in milliseconds and handles everything a typical web or mobile application needs.
Self-hosting PocketBase gives you a Firebase-like backend experience with zero vendor lock-in and total data ownership.
Key Features
- Real-time database with collections, relations, and automatic REST and real-time APIs
- Built-in authentication with email/password, OAuth2 (Google, GitHub, etc.), and API keys
- File storage with automatic thumbnailing for images
- Admin dashboard for managing collections, records, users, and settings
- Real-time subscriptions via Server-Sent Events for live data updates
- Extendable with Go or JavaScript hooks for custom business logic
- Built-in S3-compatible storage support for offloading files to MinIO or cloud storage
- Automatic API documentation generated from your collection schema
Why Self-Host PocketBase?
The simplest backend possible. PocketBase is a single binary file. No Docker required (though it works great in Docker), no database server to configure, no dependencies to install. Copy the binary to your VPS, run it, and you have a complete backend with API, auth, and file storage.
Firebase without the lock-in. Firebase gives you a real-time database, authentication, and file storage — but locks you into Google's ecosystem with proprietary APIs. PocketBase provides the same capabilities with standard REST APIs and an SQLite database you can copy, back up, and migrate anywhere.
Instant prototyping to production. Start building your frontend immediately. PocketBase's admin UI lets you create collections (tables), define fields, and set up auth without writing backend code. When you need custom logic, extend with Go or JavaScript hooks.
Minimal resource footprint. PocketBase uses SQLite, which means no separate database process consuming RAM. The entire backend — API server, database, auth, file storage — runs in a single process using 50-100 MB of RAM.
System Requirements
| Resource | Minimum | Recommended |
|---|---|---|
| CPU | 1 vCPU | 2 vCPUs |
| RAM | 256 MB | 1 GB |
| Storage | 5 GB SSD | 20 GB SSD |
| OS | Ubuntu 22.04+ | Ubuntu 24.04 |
PocketBase is extraordinarily lightweight. The single binary with embedded SQLite database uses minimal resources. Storage needs depend on your application data and uploaded files. For most projects, PocketBase runs comfortably alongside other services on a shared VPS.
Getting Started
Deploy PocketBase on your VPS using Docker Compose through Dokploy. Our guide covers persistent data storage, admin setup, SSL configuration, and connecting your frontend application.
Deploy PocketBase with Dokploy →
Alternatives
- Supabase — Postgres-based development platform with real-time subscriptions and auth
- Appwrite — Backend platform with databases, auth, functions, and storage
- Directus — Headless CMS wrapping any SQL database with an API and admin UI
- NocoDB — No-code database platform with spreadsheet UI on top of SQL databases
FAQ
How does PocketBase compare to Supabase? Supabase uses PostgreSQL and offers more advanced database features (full-text search, PostGIS, stored procedures). PocketBase uses SQLite and prioritizes simplicity — single file deployment, zero configuration. Choose Supabase for complex, data-heavy applications. Choose PocketBase for rapid development and simpler backends.
Can PocketBase handle production traffic? Yes. SQLite handles tens of thousands of requests per second for read-heavy workloads. PocketBase uses WAL mode for concurrent reads and writes. For most web and mobile applications, PocketBase performance is more than sufficient. The main limitation is write-heavy workloads at very high concurrency.
Does PocketBase support real-time data? Yes. PocketBase uses Server-Sent Events (SSE) for real-time subscriptions. Your frontend can subscribe to collection changes and receive updates instantly when records are created, updated, or deleted.
Can I extend PocketBase with custom logic? Yes. PocketBase supports hooks written in Go (compiled into the binary) or JavaScript (executed at runtime). You can add custom API routes, modify request/response handling, add validation logic, and integrate with external services.
App data sourced from selfh.st open-source directory.
Ready to get started?
Get the best VPS hosting deal today. Hostinger offers 4GB RAM VPS starting at just $4.99/mo.
Get Hostinger VPS — $4.99/mo// up to 75% off + free domain included
// related topics
fordnox
Expert VPS reviews and hosting guides. We test every provider we recommend.
// last updated: February 12, 2026. Disclosure: This article may contain affiliate links.