• Skip to main content

Uly.me

cloud engineer

  • Home
  • About
  • Archives

Json Formatter

January 12, 2022

If you have a json file that needs formatting, you can use a built-in tool in Python.

python -m json.tool sample.json

python -m json.tool sample.json

Output will be printed on screen. You can also send the output to a file.

python -m json.tool sample.json > sample2.json

python -m json.tool sample.json > sample2.json

Filed Under: Linux Tagged With: formatter, json, python

Search This Website

Subscribe Via Email

  • Home
  • About
  • Archives

Copyright © 2023