Installation
Reflex is a local-first code search engine that combines trigram indexing for full-text search with Tree-sitter parsing for symbol extraction and static analysis for dependency tracking. Unlike symbol-only tools, Reflex finds every occurrence of a pattern with deterministic, repeatable results.
Install
Section titled “Install”Choose your preferred package manager:
# npm (recommended — includes prebuilt binaries)npm install -g reflex-search
# cargo (builds from source, requires Rust toolchain)cargo install reflex-searchVerify the installation
Section titled “Verify the installation”rfx --versionYou should see output like reflex-search 1.1.1.
Project setup
Section titled “Project setup”Navigate to your project root and run:
rfx indexThis creates a .reflex/ directory containing the search index. Add it to your .gitignore:
echo '.reflex/' >> .gitignoreThat’s it — Reflex is ready. The index is fully local; no data leaves your machine.
What’s inside .reflex/
Section titled “What’s inside .reflex/”| File | Purpose |
|---|---|
meta.db | SQLite metadata (file list, stats, config) |
trigrams.bin | Trigram inverted index for fast full-text search |
content.bin | Memory-mapped file contents for result display |
config.toml | Project-level configuration |
System requirements
Section titled “System requirements”- Node.js 18+ (for npm install) or Rust 1.75+ (for cargo install)
- Works on Linux, macOS, and Windows
- No external services or network access required
Next steps
Section titled “Next steps”Head to the Quick Start to index your first project and run queries, or see Configuration to customize Reflex for your workflow.