Backend technology
GraphQLdevelopment expertise.
A query language for APIs and a runtime for fulfilling those queries with your existing data.
Category
Backend
Learning curve
Moderate
Introduced
2015
Overview
Where GraphQL fits in a modern product.
GraphQL is a query language for APIs and a runtime for executing those queries by using a type system you define for your data. It provides a complete and understandable description of the data in your API.
Single Endpoint
Strong Typing
Real-time Updates
Efficient Data Loading
Introspection
Product use cases
What teams build with GraphQL.
The technology is most valuable when its strengths match the product, team and operating context.
Complex Data Requirements
Mobile Applications
Microservices
Real-time Applications
Engineering assessment
Strengths and trade-offs, considered together.
Technology selection should account for product requirements, team capability, ecosystem maturity and long-term ownership.
Strengths
- Efficient data loading
- Single endpoint
- Strong typing
- Client-driven queries
- Real-time capabilities
- Introspective
Considerations
- Complex caching
- Learning curve
- Potential over-fetching on complex queries
- N+1 problem
Getting started
Set up a GraphQL server, define your schema, implement resolvers, and test queries using GraphiQL or Playground.
Best practices
Design thoughtful schemas, implement proper error handling, use batching for performance, implement proper security, and document your API.
Ecosystem
GraphQL ecosystem includes Apollo and Relay clients, server implementations in various languages, tools like GraphiQL, and schema stitching solutions.
Related technologies
Explore the surrounding ecosystem.
Compare adjacent frameworks, platforms and tools that commonly support similar product goals.