GraphQL Playground
Write, validate, and explore GraphQL queries, mutations, and schemas. Paste a schema to browse types and fields, or load sample queries to get started.
GraphQL Query
Variables (JSON)
GraphQL Playground
Write, validate, and explore GraphQL queries, mutations, and schemas. Paste a schema to browse types and fields, or load sample queries to get started.
Features
- Write and validate GraphQL queries, mutations, and subscriptions
- JSON variables editor with syntax validation
- Schema explorer: paste SDL to browse types, inputs, and enums
- Load sample queries to quickly learn GraphQL syntax
- Client-side only: your queries never leave your browser
How to use
- Enter your GraphQL query in the editor or click a sample button to load an example query.
- Add JSON variables in the variables panel if your query uses parameters.
- Click Execute to validate the query syntax, or switch to the Schema Explorer tab to browse types.
Tips & Best Practices
- All processing happens in your browser — no data is sent to any server.
- Use the copy button to quickly transfer results to your clipboard.
- The tool works offline once loaded — no internet connection required for processing.
- Check the FAQ section below for answers to common questions.
- Share this tool with colleagues using the social sharing buttons.
FAQ
Can this tool actually call a GraphQL API?
No. Due to browser CORS restrictions, this tool cannot execute queries against external APIs. It validates your query syntax and structure client-side so you can catch errors before running queries in your own application or API client.
What kind of validation does it perform?
The playground checks for matching braces and parentheses, valid operation keywords (query, mutation, subscription, fragment), empty selection sets, and valid JSON in the variables panel. It provides line-number references for each error found.
How does the Schema Explorer work?
Paste a GraphQL Schema Definition Language (SDL) document and click Parse Schema. The tool extracts all types, input types, and enums and displays them as browsable cards showing each field name and its type.
What sample queries are available?
Three sample queries are included: a basic users query demonstrating nested fields, a parameterized query with variables showing directives and pagination, and a mutation example with input objects and error handling.
Is my data private?
Yes. All validation and parsing happens entirely in your browser. No data is sent to any server. Your queries, variables, and schemas remain on your device at all times.
Can I use this for subscriptions?
You can write and validate subscription queries syntactically. However, since actual WebSocket connections to external servers are not supported, the subscription will not execute. The validator will still check the syntax for correctness.