GraphQL Query Builder
Add fields, arguments, and nested selections through a form and get a formatted GraphQL query string ready to copy into your client or API explorer. Runs entirely in your browser.
🔒 This tool runs entirely in your browser. Your files are never uploaded to a server.
Generated query
How it works
- Choose query or mutation, and give the operation an optional name.
- Set the root field and any arguments it needs.
- List the fields to select, indenting to nest sub-selections.
- Copy the formatted GraphQL string straight into your client.
FAQ
How do I nest fields?
Indent a line under a parent field to make it a sub-selection — for example, indent "id" and "title" under "posts" to select posts { id title }.
Can I build mutations too?
Yes — switch the operation type dropdown to "mutation" and the generated output changes its keyword accordingly.
How are arguments formatted?
Enter one "name: value" pair per line. They are joined with commas and wrapped in parentheses right after the root field, matching standard GraphQL argument syntax.
Does this send the query to a server?
No — it only formats the query text in your browser. Paste the result into your own GraphQL client, Playground, or Postman to actually run it.
How we compare
| Feature | Online Tool Store | Typing raw GraphQL by hand |
|---|---|---|
| No manual brace matching | ✓ | ✗ |
| Consistent indentation every time | ✓ | Manual |
Hand-writing nested GraphQL queries is easy to get wrong with mismatched braces. This builder generates clean, consistently indented query text from a simple field outline.