GraphQL is the new REST

GraphQL is the best way to fetch data for your app, and the GraphQL Guide is the best way to learn how.

Cover of The GraphQL Guide

The Authors

jeresig
John Resig
John Resig
John is a JavaScript expert. He created jQuery and is Chief Software Architect at Khan Academy. Nine years ago, he stepped back from jQuery and wrote his last book. He’s been exploring the power of GraphQL and is convinced that it’s the future of API development.
lorendsr
Loren Sands-Ramshaw
Loren Sands-Ramshaw
Loren is a consultant who loves teaching and writing. He has worked on Apollo and the Meteor Guide, built full-stack web and mobile apps for over a decade, founded startups, and TA’ed many Computer Science courses at Dartmouth.

Topics We Cover

View table of contents
Beginner introduction

We start out in Chapter 1 by introducing the basics of GraphQL in contrast to REST. Then in Chapters 2–4, we go through the whole GraphQL specification from its basic building blocks. We also have an extensive Background chapter that covers everything from HTTP and latency to authentication and databases.
Advanced topics

In the client chapters, we cover advanced topics like infinite scrolling, local state, prefetching, and persisting. In our server chapter, we cover schema design, four different data sources (as well as how to create your own), security, performance, and more.
Frontend

Chapters 5–10 are all about the client. You can make an HTTP request to a GraphQL API from anywhere, or you can use an advanced client library with automatic caching and view layer integration. We have chapters on React, Vue, React Native, iOS, and Android.
Backend

If you’re a backend dev, we’ve got you covered. Chapter 11 is our longest chapter, and it goes through all the server topics you could want: server structure, connecting to databases and APIs, subscriptions, custom scalars, authentication, authorization, caching, testing, and more.
React

React is becoming the lingua franca of modern web dev, so this is our longest client chapter. We go through everything in the Apollo Client library, including hooks, managing local state, subscriptions, optimistic updates, error handling, pagination, batching, linting, testing, and more.
Vue

Our Vue chapter teaches Apollo Vue’s composition API. Provide an ApolloClient instance and query inside a component’s setup function to get refs with the data, loading status, and error status. Query with variables and options, send mutations, and watch subscription results.
Android

In addition to our React Native chapter, we also have a native Android chapter based on the Apollo Android library. Get typed Kotlin models generated from your queries and mutations, configure caching, and use coroutines, ViewModel, and Flow.
iOS*

We’re working on a native iOS chapter that uses the Apollo iOS Swift client. Get your query and mutation results in query-specific Swift types, and have the data cached.
* This chapter is forthcoming (pending the v1 release of the Apollo iOS library).

Reviews

This is the most comprehensive coverage of modern GraphQL, going from the basics of the Query Language to excruciating detail on Validation and Execution internals that you’ll be thankful for when things go wrong, to the latest and greatest in the ecosystem, like Apollo Federation and Hasura. It normally takes a developer months to get up to speed on putting together all these pieces. The GraphQL Guide teaches it in just a few hours!

I really enjoyed reading the book. It is very detailed, and the different git branches are great for picking up at certain sections. I would have loved to have had this book by my side when I started GraphQL :)

I’d already had the opportunity to work with and learn GraphQL, but the GraphQL Guide really cemented the core concepts (and enlightened me on some details I’d overlooked before). I always struggled with the concept of Subscriptions in GraphQL—after reading this book, my understanding improved tenfold. Highly recommend reading if you want to be successful with GraphQL!

View more

885

Total pages

12

Chapters

5,000

Lines of code

11

Videos

Basic

39
  • The book in HTML, PDF, ePub, and Kindle formats

  • The book’s Git repositories, with branches for each section
5% of your purchase goes toward removing CO₂ from the atmosphere.

Or pay via PayPal

Pro

89
  • The book in HTML, PDF, ePub, and Kindle formats

  • The book’s Git repositories, with branches for each section

  • Free updates for two years

  • Extra sections:
    Server-Side Rendering
    Apollo Federation
    Server Analytics

  • Videos:
    Introduction to the codebases
    Apollo Devtools
    Apollo Studio
5% of your purchase goes toward removing CO₂ from the atmosphere.

Or pay via PayPal

Training

749
  • Everything in the Full edition, plus a day-long training course

  • Choose between three courses: Intro to GraphQL, Intro to Fullstack Apollo, and Advanced Dev. All use JavaScript (React and Node).

  • Advanced course topics include auth, subscriptions, caching, batching, and federation

  • Taught by Eve and Alex, our excellent education partners at Moon Highway

  • Offered periodically online (alternatively, your company can sponsor and schedule a training: sales@graphql.guide)
5% of your purchase goes toward removing CO₂ from the atmosphere.
Another 5% goes toward sponsoring open source software!

Or pay via PayPal

1 Free updates for the lifetime of the book. We’ll keep it up to date for at least 4 years, but we hope to continue for as long as GraphQL is the best data-fetching system out there. (Which is probably a long time—REST has been around for 21 years!)
2 Coming soon.

Team license

349
  • Get a 20% discount over individual pricing by ordering a group license to the Pro package for your team.

  • We can also arrange a day or two of training for your company. Inquire at:
  • sales@graphql.guide

5% of your purchase goes toward removing CO₂ from the atmosphere.

Or pay by PayPal
or by check to:

The GraphQL Guide
2443 Fillmore St #380-2914
San Francisco, CA 94115

Full team license

1000
  • Get a 30% discount over individual pricing by ordering a group license to the Full package for your team.

  • We can also arrange a day or two of on-site training for your company. Inquire at:
  • sales@graphql.guide

5% of your purchase goes toward removing CO₂ from the atmosphere.
Another 5% goes toward sponsoring open source software!

Or pay by PayPal
or by check to:

The GraphQL Guide
2443 Fillmore St #380-2914
San Francisco, CA 94115