Need advice about which tool to choose?Ask the StackShare community!

Apollo

2.7K
1.8K
+ 1
25
Hasura

336
627
+ 1
144
Add tool

Apollo vs Hasura: What are the differences?

Introduction

This Markdown code provides a comparison between Apollo and Hasura, two popular technologies used in web development.

  1. Data Layer Approach: Apollo is a flexible and powerful Graphql client that can be used with any backend. It provides client-side caching, optimistic UI updates, and schema stitching. On the other hand, Hasura is an instant GraphQL backend that connects to databases and auto-generates a GraphQL API. It allows developers to build real-time applications quickly without writing custom server-side code.

  2. Real-time Capabilities: Apollo offers real-time capabilities through its support for GraphQL Subscriptions. It allows clients to subscribe to specific events and receive real-time updates from the server. Hasura, on the other hand, provides real-time updates out of the box by leveraging built-in event-driven architecture. This means that any changes made in the database automatically trigger real-time updates to connected clients.

  3. Authorization and Authentication: Apollo provides a flexible and customizable approach to authorization and authentication. It allows developers to implement their own authentication logic using middleware or third-party libraries. Hasura, on the other hand, comes with built-in role-based access control (RBAC) and JWT authentication. This simplifies the implementation of authentication and authorization in Hasura-based applications.

  4. Direct Database Access: Apollo requires a server-side middleware or backend to communicate with the database. It doesn't provide direct access to the database but can connect to any GraphQL-compliant backend. Hasura, on the other hand, directly connects to the database and provides a GraphQL API layer on top of it. This eliminates the need for a separate backend and simplifies the development process.

  5. Developer Experience: Apollo provides a rich developer experience with tools like Apollo Client, Apollo Server, and Apollo Studio. It has a wide range of features and integrations that make it easy to develop, test, and deploy GraphQL applications. Hasura, on the other hand, provides a streamlined developer experience with its auto-generated GraphQL API and built-in console. It allows developers to focus on application logic rather than dealing with setup and configuration.

  6. Community and Ecosystem: Apollo has a large and active community with extensive resources, tutorials, and libraries available. It is widely adopted by developers and has a mature ecosystem. Hasura, on the other hand, has a growing community and ecosystem. While it may not have the same level of resources as Apollo, it is gaining popularity due to its simplicity and developer-friendly approach.

In Summary, Apollo and Hasura are both powerful GraphQL technologies, but they differ in their approach to data layer, real-time capabilities, authorization and authentication, database access, developer experience, and community support.

Decisions about Apollo and Hasura
Márton Danóczy

We wanted to save as much time as possible when writing our back-end, therefore Apollo was out of the question, we went for an auto-generated API instead. Hasura looked good in the beginning, but we wanted to retain the ability to add a few manual resolvers and modifications to auto-generated ones, which ruled out Hasura. Postgraphile with its Plug-In architecture was the right choice for us, we never regretted it!

See more
Get Advice from developers at your company using StackShare Enterprise. Sign up for StackShare Enterprise.
Learn More
Pros of Apollo
Pros of Hasura
  • 12
    From the creators of Meteor
  • 8
    Great documentation
  • 3
    Open source
  • 2
    Real time if use subscription
  • 23
    Fast
  • 18
    Easy GraphQL subscriptions
  • 16
    Easy setup of relationships and permissions
  • 15
    Automatically generates your GraphQL schema
  • 15
    Minimal learning curve
  • 13
    No back-end code required
  • 13
    Works with new and existing databases
  • 12
    Instant production ready GraphQL
  • 11
    Great UX
  • 4
    Low usage of resources
  • 4
    Simple

Sign up to add or upvote prosMake informed product decisions

Cons of Apollo
Cons of Hasura
  • 1
    File upload is not supported
  • 1
    Increase in complexity of implementing (subscription)
  • 3
    Cumbersome validations

Sign up to add or upvote consMake informed product decisions

- No public GitHub repository available -

What is Apollo?

Build a universal GraphQL API on top of your existing REST APIs, so you can ship new application features fast without waiting on backend changes.

What is Hasura?

An open source GraphQL engine that deploys instant, realtime GraphQL APIs on any Postgres database.

Need advice about which tool to choose?Ask the StackShare community!

What companies use Apollo?
What companies use Hasura?
See which teams inside your own company are using Apollo or Hasura.
Sign up for StackShare EnterpriseLearn More

Sign up to get full access to all the companiesMake informed product decisions

What tools integrate with Apollo?
What tools integrate with Hasura?

Sign up to get full access to all the tool integrationsMake informed product decisions

Blog Posts

GitHubPythonNode.js+47
54
72276
What are some alternatives to Apollo and Hasura?
Helios
Helios is a Docker orchestration platform for deploying and managing containers across an entire fleet of servers. Helios provides a HTTP API as well as a command-line client to interact with servers running your containers.
GraphQL
GraphQL is a data query language and runtime designed and used at Facebook to request and deliver data to mobile and web apps since 2012.
Python
Python is a general purpose programming language created by Guido Van Rossum. Python is most praised for its elegant syntax and readable code, if you are just beginning your programming career python suits you best.
Relay Framework
Never again communicate with your data store using an imperative API. Simply declare your data requirements using GraphQL and let Relay figure out how and when to fetch your data.
Heroku
Heroku is a cloud application platform – a new way of building and deploying web apps. Heroku lets app developers spend 100% of their time on their application code, not managing servers, deployment, ongoing operations, or scaling.
See all alternatives