Live data from Hacker News

Pocketbase – open-source realtime back end in 1 file

pocketbase.io

61–70 of 211 posts

Re: Pocketbase – open-source realtime back end in 1 file

#61
post #31

I am curious to better understand the benchmarks against simple SQLite, especially under typical load. Any level of latency will be an unnecessary overhead.

How do you use simple SQLite without any code in a webapp where the database is on the server?

You can't. I am curious if this adds another layer of latency.

Re: Pocketbase – open-source realtime back end in 1 file

#62

For those unfamiliar: this is a backend server you can configure via a GUI, so you can get a working backend with little or no code. It’s great for quick prototypes, MVPs, and simple apps. The concept was popularized by Firebase.

What does it actually do? Yes, I know what a backend is - and the backends I write have hundreds to thousands of lines of code that do very specific things. How can that be eliminated? What types of applications can be built with these tools?

It does the same things a typical CRUD backend does (REST/realtime API, authentication, authorization, validation, etc.). For example, you could use it when building a simple todo mobile app that syncs your data in the cloud. The catch is that the moment your requirements fall outside what the system supports, you are more or less f*cked.

Re: Pocketbase – open-source realtime back end in 1 file

#63

For those unfamiliar: this is a backend server you can configure via a GUI, so you can get a working backend with little or no code. It’s great for quick prototypes, MVPs, and simple apps. The concept was popularized by Firebase.

What does it actually do? Yes, I know what a backend is - and the backends I write have hundreds to thousands of lines of code that do very specific things. How can that be eliminated? What types of applications can be built with these tools?

It's meant to be a Firebase / Supabase alternative.

Yes, you can always build a better backend yourself if you know what you're doing, or you can go from zero to having a proper auth (username/password, 0auth providers, one-time emails, multi-factor) to plug into by running a binary.

Unlike Firebase, you can run it anywhere. Unlike Supabase, you don't need 10+ containers to do so.

Re: Pocketbase – open-source realtime back end in 1 file

#64

Earlier quoted context omitted.

What does it actually do? Yes, I know what a backend is - and the backends I write have hundreds to thousands of lines of code that do very specific things. How can that be eliminated? What types of applications can be built with these tools?

It does the same things a typical CRUD backend does (REST/realtime API, authentication, authorization, validation, etc.). For example, you could use it when building a simple todo mobile app that syncs your data in the cloud. The catch is that the moment your requirements fall outside what the system supports, you are more or less f*cked.

While that may be true, it is worth seriously checking the docs and working out what requirements you have or might have. Pocketbase does an awesome job of providing extensibility, likely most of the stuff you want that’s not fully out of the box can be added in 20 lines of code or so.

Re: Pocketbase – open-source realtime back end in 1 file

#67

I'll give it a try, but I'm not a fan of the SPA approach. Try using it with Templ and server-side rendering (SSR) instead of any JavaScript framework. If anyone has already done this and can share their experience, I would love to hear about it!

I can speak to this.

It works, though if you need auth/authz you'll probably want to add some middleware to get a cookie flow working instead of the jwt approach PB uses by default.

If I remember right, essentially you set the cookie on login and on auth refresh and pull it out and into the auth header on all incoming requests.

Re: Pocketbase – open-source realtime back end in 1 file

#68
We use pocketbase for a lot of our internal LoB apps and it's been bulletproof. Saved us a lot of time and money.

I'm a control freak and I like well defined endpoints with well defined performance characteristics, so the expressiveness of the API is in my mind a drawback for anything public facing, but it's undeniably a great experience on the front end, and if you design your tables with the API and filters in mind you can get to a good place.

Overposting is another thing to be aware of when the db is so ergonomically shaped to the front end

Re: Pocketbase – open-source realtime back end in 1 file

#69

I've been trying out Pocketbase on a side project idea. I'm super impressed! Having worked for many years on Django projects, Pocketbase seems like a perfect fit for those small to medium sized projects for which you don't want to create and maintain a traditional backend for. Happy to answer any questions.

I’ve been using on a personal side project - but found that LLMs seem to be permanently confused over how to interact with pocketbase - to the point where I’ve even tried creating a Claude Skill to try and reduce the confusion.

Wondering if anyone else has had a similar experience?

Re: Pocketbase – open-source realtime back end in 1 file

#70
> Please keep in mind that PocketBase is still under active development and full backward compatibility is not guaranteed before reaching v1.0.0. PocketBase is NOT recommended for production critical applications yet, unless you are fine with reading the changelog and applying some manual migration steps from time to time.
Post reply on HN