Which cloud databases will let you work with real-time features? Let’s take a look.
When we build an application, we often need real-time features. We may want notifications, chat features, real-time views, likes or live data displayed.
Building these features from scratch would require complex polling or change data capture techniques on the server, and filtering them would be even more complex. You would then need to setup up your own GraphQL, Rest API or gRPC microservice that supports some kind of Streaming or WebSocket, and it needs to include security. That is just the server end.
Finally, you need to build a client API that connects to this backend, is secure with authentication and authorization controls, and is safe to use in the browser. Luckily, some modern-day cloud database platforms include real-time capabilities out of the box.
Note: This article only mentions real-time features, not all database features.
Database (Connection limit): Cloud Firestore (1,000,000+), Real-time Database (200,000+)
Type: gRPC and WebChannels (polling for unsupported browsers), Client SDK
Cloud Firestore from Google Firebase is probably the first fully featured database platform with real time built-in. It is invariably the easiest to use and get started with.
Pros
Cons
Database (Connection Limit): Postgres (200, 500, or unlimited depending on plan)
Supabase is perhaps the second most popular database platform with real-time capabilities. They have added a bunch of new features in the last year alone.
Type: Postgres Replication, Client SDK
Pros
Cons
Database (Connection Limit): Postgres—and meta-postgres compliant databases—Microsoft SQL, Google Big Query, and has plans for many other databases built to scale (10, 100, or unlimited depending on plan).
Hasura is built to scale from small Postgres to large Yugabyte databases.
Type: Polling for live queries, Replication for Subscriptions, GraphQL Subscriptions Client
Pros
Cons
Database: Dgraph
Dgraph is a unique Graph Database that currently is working on releasing a new version in early 2023 after getting a new team of engineers and new funding.
Type: Polling (no connection limits), GraphQL Subscriptions Client
Pros
Cons
Database: FaunaDB
Fauna is a mixture of a noSQL Document Database and a Graph Database.
Type: Streaming (unlimited but charged by connections), Client SDK
Pros
Cons
Database: Appwrite (built on top of MariaDB)
Appwrite is a noSQL Document Database that can be self-hosted like Supabase. The Cloud version is available in beta (I have access), so I am including it in this list. It most likely will be available for everyone in the next few months.
Type: Event Streaming
Pros
Cons
Database: mySQL (no access)
8base is a GraphQL first database platform. You don’t have access to the core mySQL, which makes it interesting.
Type: Event Streaming, GraphQL Subscription
Pros
Cons
Database: DynamoDB (no access)
Grafbase is meant to be GraphQL first so you don’t think about anything database related.
Type: Event Streaming, GraphQL Subscription
Pros
Cons
These are the only databases I know of that currently work for real-time data without having to deploy custom middleware. Hopefully we get to see the them mature with the features we need!
Jonathan Gamble has been an avid web programmer for more than 20 years. He has been building web applications as a hobby since he was 16 years old, and he received a post-bachelor’s in Computer Science from Oregon State. His real passions are language learning and playing rock piano, but he never gets away from coding. Read more from him at https://code.build/.