Show HN: Bknd – Firebase alternative that embeds into any React stack
50 points| dswbx | 11 months ago |github.com
bknd runs directly inside your frontend app — no separate backend required. It works with Next.js, Remix, Astro, React Router. It also runs standalone on Cloudflare Workers, AWS Lambda, Bun, or Node.
It supports Postgres, LibSQL (Turso), D1, SQLite and has adapter-based storage. You get instant APIs, multi-strategy auth, media handling and a built-in Admin UI.
Curious what you’d build with it, feedback welcome!
jfengel|11 months ago
(I haven't used a system like that. I'm intrigued by the idea of a backend that's just a database but it weirds me out not to have to write a layer that says who can read what. Exposing the database that nakedly feels super dangerous.)
dswbx|11 months ago
On the Authorization side, you can create roles and attach permissions to it. Those roles then get attached to users.
Claims are transported via JWT, you can configure its lifetime, secret and hashing. Currently it's stateless, meaning the token is not checked in a session store. But if there is demand, I'd prioritize adding this. I'm mainly exactly looking for feedback to prioritize next additions.
Hope this helps.
lelanthran|11 months ago
In my (closed) product that exposes the database to the frontend, the "exposure" part has, effectively, row-level access control.[1]
[1] Also role-based using groups. I additionally mark the read-only queries as read-only and these are executed on a read-only replica.
3np|11 months ago
Core auth feature progress is tracked here: https://github.com/bknd-io/bknd/issues/6
joshuanapoli|11 months ago
Kiro|11 months ago
CalRobert|11 months ago
e12e|11 months ago
> bknd runs directly inside your frontend app — no separate backend required.
> It supports Postgres
How is the postgres credentials kept secret from the client?
abusaidm|11 months ago
dswbx|11 months ago
The database (postgres, libsql, d1, etc.) is hosted as usual. Fullstack frameworks like Next.js, Remix, Astro, etc. would run bknd on the server side exclusively.
But I see the issue. I should've written "inside your fullstack app" – my bad!
compootr|11 months ago
I frequently use pocketbase because I love its extensibility and simplicity. Is this product like pocketbase but you can edge-deploy it? (i.e more infinitely scalable?)
dswbx|11 months ago
aptj|11 months ago
dswbx|11 months ago
Not familiar with Zero, but it looks interesting, will check it out.
campak|11 months ago
dswbx|11 months ago
mediumsmart|11 months ago
rizky05|11 months ago
[deleted]