ripgrep (rg) is a line-oriented search tool that recursively searches a directory for a regex pattern. By default it respects .gitignore rules and automatically skips hidden files, directories, and binary files, which is the main thing that separates it from plain grep. It's aimed at developers who search large codebases regularly and want that search to be both fast and to automatically stay out of build artifacts, dependencies, and other files you almost never actually want to search.
.gitignore, .ignore, or .rgignore, along with hidden files and binary files, by default; disable all of it at once with rg -uuu.rg -tpy foo to search only Python files or rg -Tjs foo to exclude JavaScript, with support for teaching ripgrep new custom file types.-P/--pcre2 or --auto-hybrid-regex.-z/--search-zip, search files compressed in brotli, bzip2, gzip, lz4, lzma, xz, or zstandard without decompressing them manually first.--json output format is designed to be consumed by other tools, such as the delta syntax-highlighting pager, which can pipe ripgrep's JSON straight into a readable diff-style view.ripgrep is a strong default for searching inside any git-tracked codebase, since gitignore-aware filtering means you get relevant results without manually excluding node_modules, build output, or .git internals every time. It's also useful for large one-off searches (log files, extracted archives, big text corpora) where raw grep speed matters and Unicode correctness can't be sacrificed for it. Its file-type filtering makes it convenient for narrowing a search to just the language you're working in without writing a complex glob pattern by hand.
It's not the right tool if you need strict POSIX conformance or ubiquity across every possible environment; the README is direct that plain grep remains the better choice for that, since ripgrep doesn't conform to any standard like POSIX despite working on Windows, macOS, and Linux. It's also purely a search tool, not a file indexer that runs in the background, so every invocation walks the filesystem fresh rather than querying a prebuilt index.
Anyone wanting to try it before installing can use an unofficial online playground and interactive tutorial linked from the README, and a documented feature-comparison table (maintained by the author of ack) lays out how ripgrep stacks up against ack, ag, git-grep, and GNU grep feature by feature.
Precompiled binaries for Windows, macOS, and Linux are available on the releases page.
Via Homebrew (macOS/Linux):
brew install ripgrep
Via common Linux package managers:
sudo apt-get install ripgrep # Debian/Ubuntu
sudo dnf install ripgrep # Fedora
sudo pacman -S ripgrep # Arch Linux
Via Windows package managers:
winget install BurntSushi.ripgrep.MSVC
scoop install ripgrep
choco install ripgrep
Via Cargo, if you have a Rust toolchain (minimum supported version 1.85.0):
cargo install ripgrep
To build from source directly:
git clone https://github.com/BurntSushi/ripgrep
cd ripgrep
cargo build --release
Optional PCRE2 support can be compiled in with the pcre2 feature flag:
cargo build --release --features 'pcre2'
The binary name after installation is rg.