Backend database for self-hosting open source apps?

PWAs and offline storage are great, but if an app really wants storage, what are the most accessible options (for users) if a developer wants to let users self-host it?

By self-host here, I’m thinking of a service that provides just hosted (“cloud”) database for some popular open source database(s) – think github for app databases (i.e. storing data instead of code, and you pay say by the megabyte stored/bandwidth used). In principle – but I’m pretty sure not yet in practice because not easy enough for users – it would work for it to be generic compute instead of pure database, as long as it’s as easy/cheap/low risk as possible for users. But then I suspect there’s no suitable database hosting service either :frowning: Still, I’ll ask.

I’m thinking here about the class of apps that can run just fine from a phone (i.e. no “cloud compute” needed), but that would benefit from online database storage so that the data is accessible from multiple devices (e.g. desktop, other phones, random computers on the internet…).

What I’m hoping for:

  1. Most important: Easy, not too expensive, and safe for users to pay for to self-host and hook up to apps!
  2. Generic backend database: not necessarily SQL, but preferably with some sort of query support as well as plain old persistence
  3. Friendly enough towards PWAs that you don’t need any “cloud compute” proxying it before you can use it (again, to make it as easy as possible for users)

For 1. I guess that means having the option of setting a price cap, which I’ve NEVER seen for any cloud product. You occasionally hear of people who signed up to say AWS or Azure to play around, and ended up with a scary-number-of-digits bill when they accidentally left something open.

Crazy add-on wish: (partially-)homomorphic encryption. Note that I think without this, in many cases client side encryption can accomplish a lot.

It occurs to me that a useful halfway (well, partway…) house here might be just some simple sync mechanism between a PWA offline database and a desktop computer.

Maybe this?

But still, I’m very dubious something like that is yet accessible to all but a tiny tiny fraction of users :frowning: (if only were still being developed seriously…) Who’s going to run Couchdb on their Mac / even linux box? Many, many fewer people than might be willing to sign up to a generic host-my-data-away-from-google web service, I think.

Edit: apparently there’s life in yet