GraphQL Codegen & Tooling
Type-safe GraphQL — schema-first, code-first, and zero-codegen.
Codegen-based (run a CLI, get types)
- ★ GraphQL Code Generator (
@graphql-codegen/*) — the standard for years; presets for any client (Apollo, urql, Relay, TanStack Query). Use theclient-presetfor new projects. - Apollo Client codegen — works fine; same idea.
- Houdini — full GraphQL framework with codegen + runtime; great for SvelteKit.
@grafbase/typed-document-string— typed documents in a single string.
No-codegen (type-only inference)
- ★ gql.tada — types from your GraphQL strings via TS type inference; zero codegen step. The default for new TS projects in 2026.
- Houdini has runtime/inference paths too.
Schema authoring (server)
- ★ Pothos — TypeScript-first schema builder; type-safe; the default for new Node GraphQL servers.
- TypeGraphQL — decorator-based.
- Nexus — older code-first builder.
- graphql-tools — for schema stitching, utilities, mocks.
- Mercurius (Fastify) / graphql-yoga (multi-platform) / Apollo Server — execution layer.
Federation
- Apollo Federation — incumbent.
- GraphQL Hive — hosted schema registry; OSS self-host option.
- Cosmo (Wundergraph) — newer federation router.
- Mesh — for stitching disparate APIs into one GraphQL.
Persisted documents / hashing
@graphql-tools/relay-operation-optimizer,@graphql-codegen/persisted-operations— persisted queries; reduce payload size + improve security.- Standard pattern: hash → CDN cache, server only accepts known hashes.
Subscriptions
- graphql-ws — WebSocket transport.
- graphql-sse — Server-Sent Events transport.
- Apollo's HTTP multipart — newer alternative.
Servers / gateways with GraphQL built-in
- Hasura — generate GraphQL from Postgres / SQL Server.
- PostGraphile — same idea, Postgres-only, more configurable.
- Grafbase — hosted GraphQL platform.
- WunderGraph — composes APIs into a typed gateway.
- Stepzen (IBM) — federated GraphQL.
Validation / linting
- graphql-eslint — lint queries / schemas.
- graphql-inspector — diff schemas, find breaking changes.
Pick this if…
- Default new GraphQL client: gql.tada.
- Existing codegen pipeline: GraphQL Code Generator with
client-preset. - Server schema in TS: Pothos.
- Postgres → GraphQL: PostGraphile or Hasura.
- Federation: Apollo Federation or Cosmo.
- Schema CI checks: graphql-inspector.