OSS Tanbou

GraphQL Code Generator — generate typed application code from schemas and GraphQL operations

About these scores

OSS scale score is an unbounded metric that log-compresses and weights Stars, Watchers, Forks, and Contributors. Discovery score is the current OSS scale score minus the score at discovery. Update pace is commits in the last 30 days, growth momentum is the OSS scale score difference within the recent observation window, and OSS health is a 0–100 rating based on available recency, Community Health, and release data.

Stars
11,260
Primary language
TypeScript
License
MIT
Repository last updated
Sep 20, 2026

Overview

GraphQL Code Generator analyzes GraphQL schemas plus query, mutation, subscription, and fragment documents to generate TypeScript types, client helpers, resolver types, and other artifacts through plugins and presets.

Features and best fit

Based on official documentation; not hands-on tested · Content checked:

Generate types from both schemas and actual operation documents

The generator can combine schema information with real queries and fragments so generated types reflect the operations an application actually executes.

Sources: [2][3]

Compose output through plugins and presets

TypeScript, React, Angular, resolver, and other plugins or presets can be selected to match frontend and backend requirements.

Sources: [2][3]

For reducing drift between GraphQL contracts and application code

It fits teams that want schema changes to flow into generated frontend and backend types rather than maintaining those definitions manually.

Sources: [2]

Check plugin resolution and duplicate GraphQL packages in monorepos

Workspace hoisting can prevent the CLI from locating plugins, and duplicate GraphQL versions can produce type incompatibilities. Inspect the dependency tree in monorepo setups.

Sources: [3][4]

Official sources

  1. [1]dotansimha/graphql-code-generator repository(2026-09-21)
  2. [2]GraphQL Code Generator README(2026-09-21)
  3. [3]GraphQL Code Generator installation(2026-09-21)
  4. [4]@graphql-codegen/cli package(2026-09-21)
  5. [5]GraphQL Code Generator MIT license(2026-09-21)
Supplemental curator note

The root `0.0.0` version belongs to the private monorepo package and is not the published CLI version. `@graphql-codegen/cli` is currently 7.4.2 and requires Node.js 16+. Because plugins are loaded dynamically, pnpm/Yarn workspaces should verify that plugins resolve at the level visible to the CLI.

Try it in 3 steps

  1. 1

    Install GraphQL and the Codegen CLI

    Follow the official quick start and add GraphQL plus the Codegen CLI.

    pnpm add graphql && pnpm add -D @graphql-codegen/cli
  2. 2

    Generate an interactive configuration

    Answer prompts for the schema, documents, plugins, and generated output path.

    pnpm graphql-codegen init
  3. 3

    Run code generation

    Use the generated config to produce types and client/server artifacts from GraphQL contracts.

    pnpm graphql-codegen
Check the official README

Growth

Growth trends · Last 30 days

11,260 Stars

Trend data is still being collected.

Development activity

Last 90 days · weekly

Commits (last 30 days)
38
Open PRs
68

Development activity is still being collected.

Built with

Categories and tags

GitHub data

GitHub dataView detailed GitHub data

GitHub Topics

  • graphql
  • typescript
  • schema
  • code-generator
  • graphql-schema
  • codegen
  • resolvers
  • react
  • angular
  • csharp
  • java
  • android
Stars
11,260
Forks
1,400
Watchers
75
Open issues
409
Contributors
433
Primary language
TypeScript
License
MIT
Repository last updated
Sep 20, 2026
Write a related article

Share a guide or use case for this OSS in Markdown. Articles are published after administrator approval.

Report incorrect information

Tell us if any listing information is incorrect or outdated.