jsonrepair repairs invalid JSON documents. It can correct many common syntax problems automatically, making malformed or incomplete JSON usable without manually locating and fixing every error.
The software is available both as a library and a command-line utility. It also provides a streaming implementation for processing very large documents without loading the entire input into memory.
This is free and open source software.
Key Features
- Add missing quotes around object keys.
- Add missing escape characters.
- Add missing commas and closing brackets.
- Repair truncated JSON documents.
- Convert single quotes to double quotes.
- Replace typographic quotes with regular double quotes.
- Replace special whitespace characters.
- Convert Python constants to their JSON equivalents.
- Remove trailing commas.
- Remove JavaScript-style comments.
- Remove fenced code blocks surrounding JSON.
- Remove ellipses from arrays and objects.
- Strip JSONP notation.
- Repair escaped JSON strings.
- Strip MongoDB data type wrappers.
- Concatenate adjacent strings.
- Convert newline-delimited JSON to a JSON array.
- Streaming support for very large documents.
- Read input from files or standard input.
- Write repaired data to a new file or overwrite the input file.
Website: github.com/josdejong/jsonrepair
Support:
Developer: Jos de Jong
License: ISC License
jsonrepair is written in TypeScript. Learn TypeScript with our recommended free books and free tutorials.
Related Software
| JSON Tools | |
|---|---|
| jq | Lightweight and flexible JSON processor. It's like sed for JSON |
| fx | JSON viewer with streaming and mouse support |
| jaq | jq clone focused on correctness, speed, and simplicity. |
| gron | Transforms JSON into discrete assignments to make it easier to grep |
| gojq | Pure Go implementation of jq |
| jless | Command-line JSON viewer written in Rust |
| jnv | Navigates JSON offering a viewer and filter editor |
| JSON Editor | View, edit, format, and validate JSON |
| Dasel | Query, modify and transform structured data |
| jid | JSON incremental digger by using filtering queries |
| jo | Small utility to create JSON objects |
| jsonrepair | Repair malformed and invalid JSON documents |
| faq | Billed as a more flexible jq supporting additional formats |
| jello | Filter JSON and JSON Lines data with Python syntax |
| jq but an interoperable configuration format transcoder | |
| json-tui | JSON terminal UI |
| jqp | TUI playground to experiment with jq |
| emuto | Small language for manipulating and restructuring JSON and other data |
| svelte-jsoneditor | View, edit, format, transform, and validate JSON |
| qo | Query JSON, CSV, and TSV files using SQL |
| jql | Query and process JSON data |
| Janice | Desktop app for viewing large JSON files |
| unqery | Query and transform JSON data |
| Twig | Terminal JSON viewer and YAML viewer |
| jtc | Extract, manipulate and transform source JSON |
| pyfx | Python-native TUI JSON viewer |
| OTree | Interactive viewer for structured data |
| kirill | JSON validator |
| jshon | Parses, reads and creates JSON. It's designed to be as usable as possible |
| jsawk | Like awk, but for JSON |
| jiq | Interactive JSON query tool |
Read our verdict in the software roundup.
| Alternatives to jq | |
|---|---|
| fx | JavaScript Object Notation (JSON) viewer with streaming and mouse support |
| gojq | Pure Go implementation of jq |
| jello | Filter JSON and JSON Lines data with Python syntax |
| jless | Command-line JSON viewer written in Rust |
| emuto | Small language for manipulating and restructuring JSON and other data files |
| unqery | Query and transform JSON data |
| htmlq | Like jq but for HTML |
| faq | Billed as a more flexible jq supporting additional formats |
| jaq | jq clone focused on correctness, speed, and simplicity |
| Interoperable configuration format transcoder with jq query syntax | |
Explore our carefully curated directory of recommended free and open source software, covering every major software category.The directory forms part of our extensive collection of articles for Linux enthusiasts. It includes hundreds of detailed reviews, together with free and open source alternatives to proprietary software from companies such as Google, Microsoft, Apple, Adobe, IBM, Cisco, Oracle, and Autodesk. LinuxLinks also covers interesting projects worth exploring, Linux-compatible hardware, free programming books and tutorials, and much more. Know a useful free and open source Linux application that we haven’t covered? Tell us about it using our submission form. |


Please read our Comment Policy before commenting.