A funny thing happened after I built the NDJSON Formatter: I realized I had accidentally built most of a regular JSON formatter too.

The NDJSON Formatter was created to help inspect line-delimited JSON files, especially logs. It parses each line separately, shows which lines are valid, keeps broken lines from ruining the entire file, and makes the output easier to read. That was useful on its own, especially for Siteimp support work.

But ordinary JSON is much more common than NDJSON. Configuration files, API responses, package files, exports, structured data, and a suspicious number of “temporary” files that somehow become permanent all use JSON.

So I took the same local-first approach and built a new JSON Formatter.

What the JSON Formatter does

The tool is deliberately simple.

You can paste JSON or open a local file, then format it into readable, indented output. You can also minify it into a compact version, copy the result, and inspect the structure as an expandable tree.

That last part matters more than I expected.

Formatted JSON is useful, but once a file gets nested, reading it still turns into a tiny archaeology project. The expandable tree lets you collapse objects and arrays so you can reason through the file in layers instead of counting braces like a raccoon defusing a bomb.

The tool supports normal JSON values:

  • objects
  • arrays
  • strings
  • numbers
  • booleans
  • null

It also shows a parser error when the input is not valid JSON.

JSON and NDJSON are not the same thing

One of the small but useful parts of this tool is that it gives me a natural place to explain the difference between JSON and NDJSON.

A normal JSON file is one complete value. It might be one object:

{
  "name": "JSON Formatter",
  "local": true
}

Or it might be one array:

[
  { "level": "info", "message": "Started" },
  { "level": "warn", "message": "Slow response" }
]

NDJSON is different. NDJSON stores one JSON value per line:

{"level":"info","message":"Started"}
{"level":"warn","message":"Slow response"}

That distinction is easy to miss. If you paste NDJSON into a normal JSON formatter, it will usually fail because the whole input is not one JSON value. If you have one JSON object per line, the NDJSON Formatter is the better tool.

If you have one complete JSON object or array, the new JSON Formatter is the better fit.

Why browser-only matters

This is the part I care about most. The JSON Formatter runs in your browser. There is no account, no backend upload, and no server-side storage. I do not run ads on this website, do not have any adware installed and don't even have an analytics solution. I don't check my traffic, don't care about my volume and am not capable of stealing anything from you. But don't trust me (or anyone else) who says that. Instead, verify and test my privacy claim.

If you open a local file, your browser reads the file so the page can format it. The file is not uploaded to hluska.ca.

If you refresh or close the page, the current input is gone. That is intentional.

I do not want small developer tools to become tiny data collection machines. Sometimes you just want to look at a config file without feeding it to someone else’s server goblin.

How to test the privacy claim

The tool includes the same practical privacy test I added to the NDJSON Formatter.

After the page loads, turn off your internet connection and try using the formatter. If it still works, the formatting is happening in your browser.

You can also open your browser developer tools, check the Network tab, and then format pasted JSON or a local file. You should not see the file being uploaded anywhere.

That does not mean every browser tool is safe. It just gives you a practical way to check what this specific page is doing.

Before sharing formatted JSON

Formatting JSON makes it easier to read. It does not make the data safe to share.

Before sending formatted JSON to another person or company, check for values such as:

  • tokens
  • secrets
  • passwords
  • API keys
  • email addresses
  • usernames
  • file paths
  • machine names
  • internal URLs
  • customer data
  • session IDs
  • config values

This is especially true for configuration files and API responses. They often contain the exact kind of information that looks boring until it is suddenly very not boring. Copy only what you need. If you work with sensitive files often, it is worth learning how to sanitize data before sharing it. I know that my service does not slurp up your data, but I don't know for sure what services I don't control do. And one of the beauties of the web is that unless you've built it, you're not sure and even if you did build it, you're still not sure. So, be smart, learn how to sanitize data and think through whether you really want some random stranger reading what you're about to paste.

I think that's good advice in general.

The tools section is becoming a thing

This started with a few unrelated utilities, but the tools section on hluska.ca is beginning to feel like a small local-first toolbox.

Right now, it includes things like:

  • JSON Formatter
  • NDJSON Formatter
  • JSON-LD Sanity Checker
  • SCSS Contrast Grid
  • Django Secret Key Generator

They are not giant products. They are not trying to become platforms. They are small browser tools for practical work. They don't have ads. I don't even have Google Analytics (or anything similar) installed. Use it, don't pay me or heck, steal the code and launch your own. It's all good.

Why I built this now

The short answer is that the NDJSON Formatter made it easy. When you're roughly 85% of the way already, why not do the other 15% and build something you can use?

The longer answer is that I keep running into small jobs where I want a tool that is:

  • web based
  • private by default
  • free of ads
  • free of account requirements
  • honest about what it does
  • inspectable enough that I can reason about it

A JSON formatter is one of those tools. There are many JSON formatters online, but I wanted one that fit the same trust posture as the NDJSON Formatter. And so I built one because not everything needs to be monetized, we don't need ads or adware monitoring every single thing we do and sometimes we all need a tool that we can bookmark, use and never worry about. The internet was a lot more fun when not everything had a business plan.