
repomix
📦 Repomix is a powerful tool that packs your entire repository into a single, AI-friendly file. Perfect for when you need to feed your codebase to Large Langua
Sign in to rate this tool.
Overview

Repomix converts an entire Git repository into a single file that large language models can ingest. It accepts a local project directory, a sub‑folder, or a remote repository specified by a shorthand (`owner/repo`) or full URL, and writes the result to `repomix-output.xml` (or the chosen format) in the current working directory. The tool is targeted at developers who need to give AI assistants full repository context for tasks such as code review, refactoring, documentation generation, or security analysis.
You invoke Repomix from the command line. A plain `repomix` call packs the whole repository, while flags let you narrow the scope: `--include "src//.ts,/.md"` selects files matching glob patterns, and `--ignore "/.log,tmp/"` excludes unwanted paths. The `--remote` option fetches a repository without cloning it locally, supporting branch paths and specific commits. Running `repomix --init` creates a `repomix.config.json` file where you can store default include/exclude rules. For environments without a global install, the tool can be executed with `npx repomix@latest` or inside a Docker container, making it usable on any OS that supports Node or Docker.
The output can be formatted as XML, Markdown, JSON, or plain text. Within each format you can toggle additional sections: a file‑level summary, the directory tree, line numbers, or a parsable schema that escapes special characters. When the “output parsable format” option is enabled, the tool adds escape sequences that increase token count but keep the file syntactically safe for the target AI model. Token counting is performed per file and for the whole bundle, which helps you stay within the context window of models like Claude, ChatGPT, Gemini, or Grok.
Repomix also applies processing steps to reduce the size of the payload. The “Compress Code” option uses Tree‑sitter to keep only essential signatures and structure while stripping implementation details, dramatically lowering token usage. Separate flags let you remove comments and empty lines. Security‑focused integration with Secretlint scans for credential‑like patterns and omits those files from the final output. The CLI respects `.gitignore` files automatically, so files you already ignore in development are excluded unless you override the setting.
Typical inputs are a path to a repository or a remote URL; typical outputs are a single file in the selected format containing the concatenated source, optional metadata, and token statistics.
Details
- Pricing
- Free
- Category
- Code
Suggest an edit
Sign in to suggest an edit.
Pros and cons
Pros
- Works across macOS, Linux, and Windows; also available via Docker
- Flexible include/exclude glob patterns give precise control over what is packed
- Built‑in security scanning reduces risk of leaking secrets to AI services
- Token‑count feedback helps manage LLM context limits
Cons
- No pricing or licensing details are published on the website
- No graphical user interface; all interaction is through CLI or Docker commands
- Documentation does not specify maximum repository size or token limits for the generated file.

