An in-browser GraphQL client: write queries and variables, send them to any GraphQL endpoint, and inspect formatted JSON results or error arrays — perfect for iterating on schemas during development
Execution
Run this tool
Fill in the form, run the tool, and review the result in one place.
Learn when to use this tool, what it supports, and how real users apply it.
Key facts
Category
Development
Input types
text, textarea
Output type
interactive
Sample coverage
4
API ready
Yes
Overview
The GraphQL Playground is an interactive, in-browser client that allows you to write queries and mutations, configure variables and headers, and send requests directly to any GraphQL endpoint to inspect formatted JSON responses or error arrays.
When to use
When you need to test and debug GraphQL queries or mutations against a live API endpoint without writing code.
When you want to inspect the structure of returned JSON payloads or troubleshoot GraphQL error arrays during schema development.
When you need to verify API authentication headers or test query variables dynamically in a sandbox environment.
How it works
1Enter the target GraphQL API URL in the Endpoint field and add any required authentication headers.
2Write your GraphQL query or mutation in the Query editor, and define dynamic parameters in the Variables section.
3Click the send button to execute the request and view the formatted JSON response or error details in real time.
Use cases
Testing public GraphQL APIs to understand their schema and data structures before integration.
Debugging complex queries with dynamic variables and custom headers during backend development.
Verifying error handling by sending malformed queries or invalid variables to the endpoint.
Examples
1. Querying Country Data from a Public API
Frontend Developer
Background
A developer needs to fetch a list of continents and their codes to populate a dropdown menu in a web application.
Problem
Verifying the exact JSON structure returned by the public Countries API before writing frontend code.
How to use
Set the endpoint to https://countries.trevorblades.com/, paste the query for continents, and execute the request.