Pretty-Printing Minified JSON Files in the Terminal
If you have a compact or minified JSON file and want to make it human-readable, you can use fx to pretty-print it instantly.
Basic Command
bash
cat input.json | fxThis opens an interactive, syntax-highlighted JSON viewer in your terminal. You can expand/collapse objects and navigate deeply nested structures easily.
Output Example

Pipe From Other Commands
You can also pretty-print JSON from any tool that outputs JSON:
bash
curl https://api.example.com/data | fxor
bash
docker inspect container_id | fxWhy fx?
- No need to remember formatting flags.
- Works out-of-the-box with streams.
- YAML support with
--yamlflag.