Moayyad Faris
JSON and Data

Processed locally in your browser — not uploaded

GraphQL Query Formatter & Minifier

Format raw GraphQL queries, mutations, subscriptions, and SDL schema definitions into clean, indented code or minify them into compact single-line payload strings for HTTP POST requests. Features line-by-line syntax error detection, Copy, and Download .graphql file options. Runs entirely in your browser.

query GetUserOrders($userId: ID!, $limit: Int) {
  user(id: $userId) {
    id
    name
    email
    orders(first: $limit) {
      edges {
        node {
          id
          totalAmount
          status
          createdAt
        }
    }
}
}
}
01

How to use

  1. Paste your raw or minified GraphQL query, mutation, or SDL schema into the editor.
  2. Click 'Format Indented GraphQL' for readable, indented syntax.
  3. Click 'Minify Single Line' to produce compact JSON payload strings for HTTP POST requests.
  4. Copy or download the output as a .graphql file.
02

Understanding the output

The formatter parses GraphQL query fields, selections, arguments, and fragment blocks, applying consistent indentation and line breaks for version control.

03

Common issues & tips

  • Unclosed braces or unmatched parentheses in selection sets cause syntax parsing errors.

Frequently asked questions

Are my GraphQL queries sent to an external server?
No. Formatting and minification happen 100% locally inside your web browser.

Related tools