A jq-like command-line tool and query language for slicing, filtering and transforming Markdown files.
01mf02/jaq
A jq clone in Rust focused on correctness, speed and simplicity, usable as a jq-compatible CLI or as a library.
Open-source alternative to:jq
- Stars
- 3,809
- Forks
- 126
- Open issues
- 24
- Last commit
- yesterday
What is it?
jaq is a clone of the jq JSON processing tool, written in Rust. It aims to be a drop-in replacement for jq on the command line while providing a more predictable implementation of the jq language, and it also adds support for YAML, CBOR, TOML and XML data formats that jq does not offer.
jaq ships in two forms: a command-line program named jaq, and the jaq-core library, which compiles and runs jq programs from inside Rust code. jaq-core can be used safely in multi-threaded environments and works with arbitrary data types beyond JSON through the ValT trait.
The project reports faster startup than jq, which matters when processing many small files, and includes a benchmark comparison against jq and gojq. Its core has been audited for security, and it comes with a test suite of more than 500 tests.
Key features
- 01Drop-in command-line replacement for jq
- 02Supports YAML, CBOR, TOML and XML input formats
- 03jaq-core library for running jq programs in Rust, safe across threads
- 04Extensible to custom data types via the ValT trait
- 05Fast startup and benchmarks against jq and gojq
- 06Core audited for security and covered by over 500 tests
Use cases
- Replacing jq in shell scripts and pipelines that process JSON
- Processing large numbers of small files where jq startup time adds up
- Embedding jq-style queries in a Rust application
Quick start
- 1
Install jaq from crates.io with Cargo
cargo install --locked jaq - 2
Install jaq with Homebrew on macOS or Linux
brew install jaq - 3
Or download a binary for your platform from the releases page
Things to know
- jaq does not take countermeasures against resource exhaustion, so it may use unlimited time, memory, or stack space.
- Some jq behavior differs from jq by design, so compatibility is not complete in all cases.
Topics
FAQ
- What is jaq?
- A jq clone in Rust focused on correctness, speed and simplicity, usable as a jq-compatible CLI or as a library. jaq is a clone of the jq JSON processing tool, written in Rust. It aims to be a drop-in replacement for jq on the command line while providing a more predictable implementation of the jq language, and it also adds support for YAML, CBOR, TOML and XML data formats that jq does not offer.
- Is jaq free to use? What license does it have?
- jaq is open source under the MIT license. Check the license terms before using it in commercial products.
- Is jaq still maintained?
- Actively maintained. The last commit to jaq was on Oct 21, 2026.
- What can I use jaq for?
- Replacing jq in shell scripts and pipelines that process JSON Processing large numbers of small files where jq startup time adds up Embedding jq-style queries in a Rust application
- How do I install jaq?
- Install jaq from crates.io with Cargo: cargo install --locked jaq Install jaq with Homebrew on macOS or Linux: brew install jaq Or download a binary for your platform from the releases page
- Where can I get jaq?
- The source code and installation instructions are on GitHub: https://github.com/01mf02/jaq
Summary generated by AI from the project's README. GitHub stats refresh daily.
Related projects
A terminal JSON viewer and processor that lets you browse, fold and transform JSON interactively in the shell.
A Rust command-line tool for previewing, filtering, aggregating, joining and transforming CSV and TSV files directly in the shell.
A command-line log viewer that turns JSON and logfmt logs into human-readable output, with filtering, sorting and live follow mode.
A declarative Go package for building command line tools, with subcommands, flags, shell completion and help generation.
A CLI tool and Python library that converts the output of common command-line tools, file types, and strings into JSON, YAML, or dictionaries.