Apollo Client vs Apollo Server
Which should you use? A side-by-side look at what each one does, who it suits, what it costs, how hard it is to set up, and where each falls short.
Open source · MIT
A JavaScript and TypeScript library for loading and caching GraphQL data in web apps.
Open source · MIT
A JavaScript GraphQL server that works with Express, Koa, Hapi and similar Node frameworks.
The short answer
Choose Apollo Client if you need…
- Developers building React apps that query a GraphQL API
- Teams using TypeScript who want typed GraphQL operations
- Apps that need a client-side cache for GraphQL responses
Choose Apollo Server if you need…
- Node.js developers who want to add a GraphQL API to an existing Express, Koa or Hapi app
- Teams that prefer defining a schema first and then implementing resolvers
- Developers who want a widely used, MIT-licensed GraphQL server in TypeScript
Side-by-side
| Apollo Client | Apollo Server | |
|---|---|---|
| Type | Library | Library |
| Price | Free and open source | Free and open source |
| Licence | MIT | MIT |
| GitHub stars | 19.8k | 14k |
| Setup difficulty | Intermediate | Intermediate |
| How you get it | Install with a package manager | Install with a package manager |
| Main language | TypeScript | TypeScript |
| Last code update | 5 days ago | 5 days ago |
What each one is
Apollo Client
Apollo Client is a library that lets a front-end app fetch data from a GraphQL server and keep the results in a local cache. It works with React, Vue, Angular, and plain JavaScript, according to the README. The README says it offers caching, APIs for queries, and developer tools.
Apollo Server
Apollo Server is a JavaScript library for running a GraphQL API on Node.js. You describe your data with a GraphQL schema and write resolver functions that fetch the data for each field. It plugs into common Node web frameworks so clients can send GraphQL queries over HTTP. The description says it is spec-compliant and built for a schema-first way of working.
Best for
Apollo Client
- Developers building React apps that query a GraphQL API
- Teams using TypeScript who want typed GraphQL operations
- Apps that need a client-side cache for GraphQL responses
Apollo Server
- Node.js developers who want to add a GraphQL API to an existing Express, Koa or Hapi app
- Teams that prefer defining a schema first and then implementing resolvers
- Developers who want a widely used, MIT-licensed GraphQL server in TypeScript
Strengths
Apollo Client
- Caching is included out of the box, per the README
- Works across several front-end frameworks
- Has TypeScript support and an active maintainer team listed in the README
Apollo Server
- Built to follow the GraphQL spec and designed for production use, per its description
- Works with several popular Node.js web frameworks
- Open source under the MIT license with a large community (about 14,000 stars)
Not ideal for
Apollo Client
- Projects that do not use GraphQL, since the library is built around GraphQL queries
- Developers who only need a simple HTTP request library, since this adds a larger set of concepts
- Non-developers, because it is code you add to an app
Apollo Server
- People who only need a REST API or static site, since GraphQL adds a layer they would not use
- Non-programmers, because it requires writing server code in JavaScript or TypeScript
- Projects that need a non-Node.js server language, since this library runs only on Node.js
Trade-offs
Apollo Client
- Requires understanding GraphQL and the library's caching model
- The README is truncated, so the full feature list and edge cases are not covered here
Apollo Server
- Requires working knowledge of GraphQL concepts such as schemas and resolvers
- The README excerpt provided is truncated, so details on configuration and advanced features could not be verified here
- Being a JavaScript/TypeScript library, it is only useful within the Node.js ecosystem
Getting started
Apollo Client
Install the client and GraphQL package
npm install @apollo/client graphqlApollo Server
Install the server package
npm install @apollo/server graphqlFrequently asked questions
What is the difference between Apollo Client and Apollo Server?
Apollo Client: A JavaScript and TypeScript library for loading and caching GraphQL data in web apps. Apollo Server: A JavaScript GraphQL server that works with Express, Koa, Hapi and similar Node frameworks. Apollo Client suits developers building react apps that query a graphql api, while Apollo Server suits node.js developers who want to add a graphql api to an existing express, koa or hapi app.
Are Apollo Client and Apollo Server free?
Apollo Client: Free and open source. Apollo Server: Free and open source.
Is Apollo Client or Apollo Server more popular?
Apollo Client has more GitHub stars (19.8k) than Apollo Server (14k). Popularity isn't the same as fit — check which one matches your use case above.
What are other alternatives to Apollo Client and Apollo Server?
Other options people compare them with include Relay, Koa.
Keep comparing
Built from our catalogue entries for both products: open-source details come from each project's README (AI-assisted, refreshed weekly) and GitHub data; AI-tool details are editorial. Spotted something wrong? Let us know from either product's page.