Import Data

JSON Paste JSON data
JSON Schema Paste Schema definition
Select type
About JSON Formatter — jsonview.dev

JSON Formatter & Beautifier — What is jsonview.dev?

jsonview.dev is a free online JSON formatter and visual editor. Paste any raw or minified JSON to instantly format, beautify, and validate it — then edit fields directly in an interactive tree view. No installation, no account required.

Key Features of this JSON Formatter

  • JSON formatter & pretty-printer — instantly format and indent any raw or minified JSON
  • JSON beautifier — syntax-highlighted output with collapsible nodes
  • JSON validator — syntax errors are caught and reported immediately on paste
  • Visual tree editor — add, rename, delete, and reorder fields with drag-and-drop
  • Type switcher — toggle any field between string, number, boolean, null, object, and array
  • Import JSON — paste raw JSON and watch it parse into an editable tree instantly
  • Import JSON Schema — scaffold a JSON structure from a draft-04/07 schema definition
  • Export JSON Schema — generate a schema from your current tree with one click
  • Random value generator — populate fields with semantically appropriate sample data
  • Field search — filter visible nodes by key name (Ctrl+F / ⌘F)
  • Compact & pretty modes — toggle between minified and indented output
  • One-click copy — copy the full JSON to clipboard instantly
  • Runs 100% in-browser — your data never leaves your machine

How to Format JSON Online

  1. Paste any raw or minified JSON into the editor — it will be formatted and pretty-printed instantly.
  2. Or click + Field to build a new JSON structure from scratch.
  3. Click the type badge (e.g. str, num) next to any field to change its type.
  4. Use to add a child field inside an object, or + to add a sibling.
  5. Drag the handle to reorder fields within the same level.
  6. Click ⚄ Random to fill all primitive fields with smart sample values.
  7. Click Copy to copy the formatted JSON output to your clipboard.

JSON Formatter FAQ

Is this JSON formatter free?

Yes. jsonview.dev is completely free with no usage limits, no account, and no install.

Does my JSON get sent to a server?

No. The formatter runs entirely in your browser. Your JSON is never transmitted or stored on any server.

What JSON Schema versions are supported?

JSON Schema draft-04 and draft-07 (subset). $ref is not supported — please dereference before importing.

Can I use this to validate JSON?

Yes. The formatter catches syntax errors immediately when you paste JSON and highlights the problem. For full schema validation, export the JSON Schema and run it against a dedicated validator.

What browsers are supported?

Any modern browser: Chrome, Firefox, Safari, Edge. JavaScript must be enabled.

JSON 格式化工具 — jsonview.dev 是什么?

jsonview.dev 是一款免费的在线 JSON 格式化与可视化编辑工具。 粘贴任意原始 JSON 即可一键格式化、美化和验证, 同时支持在交互式树形界面中直接编辑字段。无需安装,无需注册。

JSON 格式化工具核心功能

  • JSON 格式化 / 美化 — 一键将压缩 JSON 格式化为缩进可读格式
  • 语法高亮 — 带折叠节点的彩色输出,结构一目了然
  • JSON 校验 — 粘贴即时检测语法错误并提示
  • 可视化树形编辑 — 拖拽排序,支持增删改字段
  • 类型切换器 — 一键切换 string、number、boolean、null、object、array
  • 导入 JSON — 粘贴原始 JSON,自动解析为可编辑树
  • 导入 JSON Schema — 根据 Schema 定义快速生成 JSON 结构
  • 导出 JSON Schema — 将当前树结构一键导出为 JSON Schema
  • 随机值生成 — 为所有字段自动填充语义合理的示例数据
  • 字段搜索 — 按字段名过滤节点(Ctrl+F / ⌘F)
  • 紧凑 / 格式化模式 — 在压缩输出和缩进输出之间切换
  • 一键复制 — 将完整 JSON 复制到剪贴板
  • 纯本地运行 — 数据不会离开你的浏览器

如何在线格式化 JSON

  1. 将任意原始或压缩的 JSON 粘贴到编辑区,立即自动格式化美化
  2. 或点击 + Field 从零开始构建新的 JSON 结构。
  3. 点击字段旁的类型标签(如 strnum)切换数据类型。
  4. 使用 在对象内添加子字段,使用 + 添加兄弟字段。
  5. 拖动 手柄对同级字段进行排序。
  6. 点击 ⚄ Random 为所有基本类型字段填充示例值。
  7. 点击 Copy 将格式化 JSON 复制到剪贴板。

JSON 格式化常见问题

这个 JSON 格式化工具是免费的吗?

是的,jsonview.dev 完全免费,无使用次数限制,不需要注册账号,也不需要安装任何软件。

我的 JSON 数据会上传到服务器吗?

不会。格式化操作完全在浏览器本地运行,你的 JSON 数据不会发送到任何服务器。

支持哪些 JSON Schema 版本?

支持 JSON Schema draft-04 和 draft-07 的子集。不支持 $ref,请在导入前将其展开(dereference)。

可以用来验证 JSON 格式是否正确吗?

可以。粘贴 JSON 时会立即检测语法错误并高亮提示。如需完整的 Schema 校验,可导出 JSON Schema 后使用专门的校验工具。

支持哪些浏览器?

支持所有现代浏览器:Chrome、Firefox、Safari、Edge,需要开启 JavaScript。