Guide
How to open, share, and explore JSON in Fast JSON Viewer.
Opening JSON files
There are three ways to load JSON into the viewer:
- Drag & drop — drag a
.jsonfile onto the page. The file is streamed in 256 KB blocks across multiple web workers; first-page render begins before parsing finishes. - LOAD FILE — click the button on the landing screen to open the native file picker. Tested with files up to 10 GB.
- Paste from clipboard — press Ctrl/⌘+V anywhere outside a text input. The pasted text is wrapped as a synthetic
pasted.jsonfile and runs through the same parsing path as a drop.
Tabs
The viewer has five tabs. Press 1 / 2 / 3 / 4 / 5 to switch.
- Viewer (1) — pretty-printed JSON with virtual scrolling and top-level collapse/expand, plus a streaming Download formatted .json export of the pretty-printed output.
- Raw (2) — the file's raw text content as a scrollable view.
- Hex (3) — a hex + ASCII dump of the file's bytes. Each row shows a byte offset (left), 16 bytes in hex (middle), and the printable ASCII representation (right). Click-drag selects bytes and the selection highlights in both the hex and ASCII panes. Useful for spotting BOM markers, non-printable characters, encoding glitches, and "why does this JSON refuse to parse" mysteries.
- Stats (4) — an instrumentation waterfall plus per-worker throughput (bytes, chars, ms, MB/s).
- YAML (5) — the parsed JSON rendered as block-style YAML with the same virtual scrolling, plus a streaming Download .yaml export. Available once the file validates; the line index is built lazily on first open, so huge files only pay for it if you use the tab.
Sharing JSON via URL
Append #jsonString= followed by your JSON to the viewer URL and the page opens with that JSON already loaded. There is no upload — the JSON travels entirely inside the URL fragment, which the browser never sends to a server.
Raw (default)
Percent-encode the JSON and append it to #jsonString=. For {"I":"love json"}:
https://fastjsonviewer.com/#jsonString=%7B%22I%22%3A%22love%20json%22%7D
▸ Try it
Base64url
For shorter or noisier URLs, base64url-encode the JSON (RFC 4648 §5 — -/_ instead of +//, padding optional) and add &encoding=base64:
https://fastjsonviewer.com/#jsonString=eyJJIjoibG92ZSBqc29uIn0&encoding=base64
▸ Try it
Build a link from the console
// raw (percent-encoded)
location.hash = 'jsonString=' + encodeURIComponent(JSON.stringify({ I: 'love json' }));
// base64url
const b64 = btoa(JSON.stringify({ I: 'love json' }))
.replaceAll('+', '-').replaceAll('/', '_').replaceAll('=', '');
location.hash = 'jsonString=' + b64 + '&encoding=base64';
Sample JSON files
The test page is a gallery of small JSON examples: ~80 valid and intentionally invalid fixtures. Click any link to open it in the viewer.
How to perf-test this app
Open the JSON test-file generator, pick a target size (anywhere from 1 KB to 20 GB), and the page streams a synthetic JSON file straight to your disk via the File System Access API. Drop the result onto the viewer and watch the Stats tab to compare parse throughput across machines, browsers, and file shapes. The first key of the generated file is always a generated header so you can tell test files apart later.
showSaveFilePicker yet — the generator will tell you.How it works
A look under the hood at the parsing pipeline and viewer.
Parallel chunk parsing
The file is split into N equal chunks, one per web worker. Each worker streams its chunk in 256 KB blocks, running a branchless byte-level parser across 23 boundary scenarios. Results are stitched on the main thread by selecting the scenario that matches the prior chunk's exit state.
Virtual scroll viewer
A sparse line → byte-offset index is built during parsing. The viewer slices only the bytes needed for the visible viewport. First-page rendering begins immediately, before parsing finishes.
UTF-8 chunk boundaries
Before dispatching workers, the main thread sniffs each chunk boundary to ensure it does not split a multi-byte UTF-8 sequence. Boundaries are nudged backward by up to 3 bytes as needed.
Keyboard shortcuts
| 1 / 2 / 3 / 4 / 5 | viewer / raw / hex / stats / yaml |
| gg / Home | go to top |
| G / End | go to bottom |
| j / ↓ | scroll down one line |
| k / ↑ | scroll up one line |
| d / u | scroll half page |
| Ctrl+F / / | focus search |
| Ctrl/⌘+V | paste JSON from clipboard |
| Enter / ⇧Enter | next / prev match |
| Esc | clear search / close |
| ? | toggle settings |