juniorGraphQL
What is the GraphQL Schema Definition Language (SDL)?
Updated Apr 28, 2026
Short answer
SDL is a syntax used to define the schema of a GraphQL API, including types, fields, and relationships.
Deep explanation
The schema serves as a strict contract between the client and server. It defines what queries and mutations are available, what custom types exist, and how they relate. It is language-agnostic.
Real-world example
Frontend and backend teams agreeing on an SDL file before development, allowing parallel work.
Common mistakes
- Confusing SDL with JSON. SDL defines the structure, while JSON is the response format.
Follow-up questions
- What does the exclamation mark (!) mean in SDL?