feature
briven
firebase
data model
the shape of your data lives in this row, and it decides most of the rest.
relational. tables, columns, foreign keys, constraints, transactions.
document. collections of json-like documents with nested subcollections.
query language
sql. joins cost you a keyword.
the firestore query api. joins are fan-out reads or denormalised copies you maintain.
transactions
postgres acid transactions across as many tables and rows as you like.
transactions, bounded by firestore's document limits.
vector search
pgvector 0.8.6 already switched on when the database is created, in the same database as your rows.
firestore vector indexes, configured per collection.
how apps connect
a pooled postgres connection string, or one statement posted to /api/v1/sql over plain http.
the firebase sdks, or the firestore rest api.
sql over http
yes — /api/v1/sql speaks neon's protocol, so a stock @neondatabase/serverless client works unmodified.
no sql surface. queries go through firestore's api.
realtime
firebase wins the offline half, which is the half a mobile app needs.
changes pushed to your application as they happen — 11 milliseconds from commit to delivery, measured against a 200 millisecond budget. no offline sync, and no recomputed query results.
snapshot listeners and offline sync — mature, and the reason most people choose firebase.
auth for your end users
firebase wins this outright.
not available. briven auth signs you in to the briven dashboard, not into your app.
firebase auth: broad oauth, phone auth, anonymous accounts, all bundled.
authorization
organisations, custom roles and a permission per resource and operation, checked on the server. api keys can be scoped to one database and marked read-only.
security rules, evaluated against every client query.
file storage
an s3-compatible bucket per database.
cloud storage for firebase, on google cloud storage underneath.
getting your data out
pg_dump. any postgres on earth can restore it.
firestore export to cloud storage, in google's own format.
branching, history and undo
copy a database in half a second and bin the copy when you are done — 256 mb in 524 milliseconds, measured. and a change log row by row, with an undo that refuses rather than guessing when the row moved on since. starter and above for the history.
a second firebase project is the usual way to get a second environment.
backups
firebase wins the off-site copy.
a full backup every night plus the write-ahead log archived continuously, and the restore has been performed on the live server rather than assumed. you can also name your own restore points. the repository is not off-site yet.
scheduled backups and point-in-time recovery.
pricing
four flat plans — free, starter, pro, enterprise.
pay per read, per write, per delete, per gb. famously hard to predict before you ship.