Get the top HN stories in your inbox every day.
rijavecb
Daynil
I feel like super easy to host needs to be re-emphasized. We're talking about dropping a single binary into your server and you're off to the races. If only more things were so simple.
imnotreallynew
Isn’t that how any Go project is put online?
paulgb
The key distinction here seems to be that it uses an in-core database (SQLite), whereas a Go project may depend on an out-of-core database like Postgres, which would then also have to be deployed.
For many projects (especially hobby projects where downtime is tolerable), the former is probably quite sufficient.
tronikel
Didnt docker make this easy for all projects?
noodlesUK
Not really because then projects started needing multiple containers and orchestration, and might be fussy about the order the different services come up.
serf
the +docker step already adds friction, so I can see the point.
pixelatedindex
Is that the same concept that Deno uses?
mdnahas
I've been developing on PocketBase for 2 months. The system goes into production in 1 to 2 months.
I'm exceptionally happy with it. I'm developing an webapp for a friend's company and wanted a very simple system to hand-off. The whole thing is running with one binary: Pocketbase. It runs a webserver, server-side Javascript (compiled TypeScript) code, and SQLite database. The single process is hosted on Vultr for $12 per month. My frontend is written in SvelteKit (static adapter) + Svelte + TypeScript.
Pocketbase is well done. The author has been exceptionally responsive to my questions. He is fast and clear.
I have had a few minor issues: The documentation has bare spots (but is very good for most things). I had to write my own CSV loader. (I hope to open-source it.) Writing lots of objects through the CRUD interface is slow. (It's possible to write faster using server-side code.) Unit testing for the server-side JavaScript had to be shoehorned in. And I wish Copilot/ChatGPT could answer questions better. But these issues have been minor, given all my work on the project.
It has some quirks. There's no way to set the 404 page on the webserver. And the binary's location in the filesystem matters. It was designed for the author's use and you have to live with these choices.
As I said, I've been happy using it. It fit my needs exactly: simple and I could code everything in one language, TypeScript. Pocketbase is not high-performance, but I didn't need that. I've had a few ideas for side projects and, when I'm done this work, I'll implement one on Pocketbase because it is that easy.
And, as part of my contract, my friend's company will donate to Pocketbase. :)
__e
> And, as part of my contract, my friend's company will donate to Pocketbase. :)
What a positive way to give back! Kudos!
jddj
I've been using Pocketbase in production for a few months now, with alpinejs on the front end.
The development philosophy is on point. It's genuinely pleasant, pragmatic software which serves a real purpose and it improves weekly without feature creep.
I watch the discussions and issues slowly getting more tiresome as it becomes more mainstream and worry that he'll burn out trying to keep up with the level of support he's offered until now.
I would very strongly encourage anyone using this to generate income to support the project on open collective.
jslakro
What other technologies in the stack you have?
jddj
There are two C# services which do some background bits and pieces.
This logic could have been put within pocketbase as well, but the body of work they depend on was already .net.
Other than that it's just little JavaScript callbacks in the back and typescript in the front.
There isn't much missing that you truly need to bolt things on for, provided SQLite is appropriate for your usecase.
BilalBudhani
I have been following PocketBase since its early day - what I absolutely love about this project is how it actively tries to avoid complexity and focuses on simple yet minimalist approach. Moreover, the ease of deployment by simply uploading a single binary on the server makes it even more attractive.
After they introduced Javascript support in the backend - I feel it became a serious contender to challenge Remix, Next.js etc. frameworks.
Looking forward to v1
d1sxeyes
I use PocketBase for mostly everything where I need a back end now. I came across a situation where I needed to write a custom SQL join (technically I could have just fetched all the data and done it in Node, I suppose).
I was shocked at how easy it was to write the query even inserting URL parameters and selecting based on the authenticated user only.
Fully recommend for basically everything. Great app. Not sure it would replace Next or Remix, but definitely add to the stack to simplify.
BilalBudhani
Interesting! I haven't made anything serious yet with the PocketBase (mostly due to lack of time & not anything to do with PB).
I'm curious to know what kind of projects did you build using PB and how was your development experience?
d1sxeyes
Bits and pieces. A bedtime tracking app for my kid, a microblog, a TikTok clone, a budget app, a text-to-speech app with translation functionality…
Development experience was outstanding. I primarily use SvelteKit and integrate PocketBase for SSR, so I use the SDK almost exclusively and it’s fantastic. Everything just works exactly the way you would expect.
I can’t imagine anything easier to implement, and as yet, I haven’t found any major gaps in what I can do with it, normally with OOB functionality.
Development velocity is very high and the developer is super responsive on GitHub. The documentation is very good and kept up to date pretty well.
My only real concern is that the project has a pretty poor bus factor, otherwise, I’m very impressed.
ilrwbwrkhv
One of my production projects with around 20,000 customers and 400k arr runs on Pocketbase with zero issues. I cannot recommend it enough.
harha_
it actively tries to avoid complexity
Sounds refreshing.
melicerte
I was looking for a frontend I could use out of the box on top of a sqlite database to design and store my wine collection (since I removed Vivino and its 800+ "partners" it shares my data with).
Looks like a single executable, the admin interface and the database I can store on my laptop (and add it to my backup) is all I was looking for. Thank you for PocketBase and thank you for sharing it.
That's why I always come back to HN :-)
karencarits
It is great to see the number of good opensource projects in this area. Grist and NocoDB deserve mentions, although more targeted towards database management. It is also amazing that they provide so simple ways to get started (single file/electron)
slig
Did not know about either of those, thanks. I've been using Baserow for small projects that I believe Pocketbase is a way better fit.
notyoutube
I've skimmed at the docs, and it's not clear to me how it would deal with:
* Something like row-level access control, so that people can only access the data in tables that belong to them (say clients can only view their own purchases, and also not modify them after they checked them out).
* Integration with the rest of the world, e.g. sending email, acting on triggers, etc.
* Something like CSV export/import.
* Internationalization.
Would that all be possible? Straightforward? Do those all require extending (with go or js)?
Looks like a nice tool.
mdnahas
I've been developing for PocketBase for 2 months.
As someone else mentioned, API rules can control access to rows.
It can send emails. Set timers. And send its own requests to other webservers. (I haven't used any of these features.) https://pocketbase.io/docs/js-sending-emails/
I had to write my own CSV importer. (I'm hoping to open-source it.)
As for internationalization, what specific features did you want? That seems more like a front-end feature.
notyoutube
Re internationalization, I think you're right. I don't have experience building app/websites, a fortiori with internationalization, so I threw this question in with the lot!
flaviocopes
Check out
API Rules https://pocketbase.io/docs/api-rules-and-filters/#api-rules
Hooks https://pocketbase.io/docs/js-overview/
Admin panel has backups for data, and import/export of collections schema
jddj
The first point (authn) is inherent to the unextended framework via filter rules.
Most of the remainder requires extension other than authz emails, but extension at its simplest just means adding a plain old JavaScript function to run on a record lifecycle event of some kind - typically [before/after] [insert/update/delete] of <record>. Various GO APIs are exposed to the JavaScript runtime for doing filesystem, cryptography, http, email, etc work.
For i18n you have templates and a database.
ilrwbwrkhv
Out of all the PaaS I tried including Supabase and Appwrite, Pocketbase is the best. Great performance, intuitive features, actually self hosted and a joy to deploy.
sonovice
Have been using pocketbase in production for a mobile app for a couple of month now and so far it was a _very_ pleasent experience. Together with the JS SDK it is now my go to backend framework for everything where I don't need specialized libraries (like ML stuff etc.)
fayazara
Pocketbase is amazing, I had made a small starter with nuxt 3.
https://github.com/fayazara/pocketbase-nuxt
Example has 1. Auth 2. Route rules 3. CRUD actions 4. Realtime events 5. Storage
Needs refactoring but I really enjoyed working with it, I want to add stripe subscriptions to this taking routes rules to it's limits, not sure how yet, will figure it out.
efields
The demo is kind of incredible. It’s the admin ux of an app we built internally over 2ish years.
It’s just… right there :)
Ilasky
Been using Pocketbase for almost all of my projects lately. Its realtime database is especially nice to introduce multiplayer functionality with relative ease.
It plus SvelteKit has been a dream to get up and running using the JS SDK.
overbytecode
I’m curious how you’re integrating it with Sveltekit? Are you using Sveltekit just as a static generator?
Ilasky
Depends upon the project.
For CRUD apps, sveltekits progressive enhancement and form actions make it quick to to add simple function to the page. You can store the pocketbase instance, pb, in locals and reference it all over the application.
For more multiplayer things, sticking a client-side subscription to a collection allows updates of elements that can be worked with/added/moved around etc.
Get the top HN stories in your inbox every day.
Pocketbase is amazing! So far I had a great experience using it as a backend/database for the app I'm building where I'm using React with Vite for the frontend. I'm using it mainly for auth and for keeping track of paid and free accounts. Some things that I found rather useful:
- It's super easy to host. I was initially thinking of using Appwrite or Supabase but found it a tricky to self-host them, especially Supabase. I could spin up Appwrite quickly via CapRover, but found it an overkill for what I needed.
- View collections [1] make it easy to return just a subset of the data that you need. In my case I'm using a view collection as a join for users and paid_users collections, where I just return their paid through date.
- The fact that you can extend it with Go or JS [2] should make it possible to completely skip having a backend, at least if your needs aren't very complex.
I definitely plan to continue using it for some smaller/side projects. Currently I'm thinking of trying to use it as CMS for an Astro blog and in the future as backend for some browser extensions.
[1] - https://pocketbase.io/docs/collections/#view-collection
[2] - https://pocketbase.io/docs/use-as-framework/