A friend and I recently started working on a new side project. We decided to take the opportunity to experiment with a new tech stack. After settling on using SvelteKit, we wanted something lightweight and easy to use as our backend and database.

After some browsing, we found a lot of people mentioning having a great experience using PocketBase in conjunction with SvelteKit. So without overthinking it, we decided to run with these referrals and dive headfirst into this new stack.


What is PocketBase

PocketBase is an open-source backend, consisting of a single file executable with an embedded database. It’s built with Go and is focused on simplicity and ease of use.

Some of its key features are:

  • Contains an embedded SQLite database
  • Supports real-time subscriptions for database updates
  • Manages user authentication and supports a wide array of OAuth2 providers (also supports plain email/password authentication)
  • Provides a convenient dashboard for managing collections
  • Fully extendable through Javascript and Go hooks

OAuth Provider options

Setting things up

Setting things up with PocketBase really couldn’t be easier. All you need to do is download the prebuilt executable file from their docs. After downloading and extracting it, you just need to run the following command in the extracted directory:

./pocketbase serve

And just like that PocketBase is up and running! You can then navigate to the dashboard and create an admin account to start setting up your tables (collections) and your auth providers.

Pocketbase Dashboard UI

What I like about PocketBase

Quick to set up

Firstly, PocketBase takes negligible time to get up and running. This is a true breath of fresh air. When you are just trying to prove out an idea quickly this speed is exactly what you need.

Don’t get me wrong, I love nothing more than setting up a well-crafted backend application with a crisp deployment pipeline. But when I just want to spend a few hours to flesh out an idea as a proof of concept, it’s hard to beat PocketBase in this area.

Inline sample queries crafted for your collections

Once you have set up your collections, the dashboard offers a handy fly out panel shown when you click ‘API Preview’ that provides sample queries for various actions you might want to perform. It also lists comprehensive details about the inputs to each API and sample responses.

Pocketbase API panel

Again, this made creating an initial proof of concept a breeze.

Easy to host

Hosting PocketBase is also super straightforward. In the official documentation, they list a couple of strategies. Since PocketBase is just a single binary, the first option they suggest is to simply upload the executable to your server and run the serve command (the same as you would do locally). Easy as that your application on the server can make calls to your PocketBase backend.

More advanced options are to use a reverse proxy or to deploy using Docker.

Things to be aware of

Pocketbase is still pretty new and actively being developed, so it’s expected that you are willing to accept breaking changes as it’s updated. So bear that in mind for your project’s needs. It’s not recommended currently to use it for “production critical applications” without paying careful attention to the project’s changelogs and potentially performing manual work to adapt your database to new changes. As of the time of writing, PocketBase is in version 0.22.9.

You should also consider your project’s needs when considering using PocketBase. It is a fantastic tool for smaller projects that you want to spin up quickly, but SQLite does have limited scalability, so bear that in mind should you expect large amounts of data and concurrent users.


Side projects are always a nice opportunity to try out cutting-edge tools and get a feel for what’s hot in the industry. PocketBase is just the latest in the never-ending torrent of these new tools, but so far I am thoroughly enjoying working with it. Spending time working with legacy applications gives you an appreciation for when something just works. And PocketBase does just that. This has been a refreshing experience and I can certainly recommend you try it out in your next hobby project.