Skip to main content
Toollabz

Formatador JSON

Paste JSON to pretty-print or minify it. The parser runs in your browser so the document does not need to leave the device for this task.

Esta página traduz o original em inglês. O motor de cálculo é o mesmo.

Versão em inglês

Resposta rápida

It parses the text as JSON and reprints it with indentation, or compactly, or reports the first syntax error.

Exemplo: {"a":1} becomes a two-line pretty document with an indented key.

Os cálculos seguem a fórmula desta página; o arredondamento e as unidades podem alterar o último dígito. Trate o resultado como uma estimativa educativa.

* Estimativa. Os valores reais podem variar consoante as hipóteses.

O que faz esta calculadora

It parses the text as JSON and reprints it with indentation, or compactly, or reports the first syntax error.

Para quem é

Developers checking API payloads, config files or a copied object.

Como funciona o cálculo

JSON.parse on the input, then JSON.stringify with a chosen indent. Errors come from the parser, not from a server.

Fórmula

Parse → reprint. No numerical formula.

Pressupostos

  • Input is text you are allowed to process locally.
  • Standard JSON, not JSON5, unless the page says otherwise.

Limitações

  • Very large documents may hit browser memory limits.
  • Does not fetch URLs for you.

Como usar esta ferramenta

  1. 1Paste the JSON.
  2. 2Choose format or minify.
  3. 3Fix the reported line if the parser fails.

FAQ

Why did it fail on a trailing comma?
Standard JSON does not allow trailing commas. Remove them or convert the file.
Is my data sent to Toollabz?
Formatting runs in the browser. Do not paste secrets into any third-party page if your policy forbids it.

Ferramentas relacionadas

Formatar e validar JSON | Toollabz