> [!IMPORTANT]
> **NEW in 4.0.0:** tweakcc now has an API; use `npm i tweakcc` to add to your project and see [API](#api)!
>
> **NEW in 4.0.0:** You can now create custom patches via sandboxed scripts! Works with native installations. No need to fork tweakcc just to make a quick patch! See [`tweakcc adhoc-patch`](#cli-commands).
>
> **NEW in 4.0.0:** You can also apply customizations from a remote URL to a config file. See [Remote Config](#remote-config).
>
> Also see `tweakcc --restore`, [`tweakcc unpack`](#cli-commands), and [`tweakcc repack`](#cli-commands).
> [!NOTE]
> **NEW:** tweakcc 4.0.0 also introduces several new patches:
>
> - [AGENTS.md support (demo video)](#feature-agentsmd-support)
> - [:lock: unlock session memory (blog post)](https://piebald.ai/blog/session-memory-is-coming-to-claude-code) (thank you [@odysseus0](https://github.com/odysseus0)!)
> - [`/remember` skill](https://piebald.ai/blog/session-memory-is-coming-to-claude-code)
> - [input pattern highlighters](#feature-input-pattern-highlighters)
> - [Opus plan 1M](#feature-opus-plan-1m-mode)
> - [MCP startup optimization](#feature-mcp-startup-optimization)
> - [token count rounding](#feature-token-count-rounding)
> - [statusline throttling/pacing](#feature-statusline-update-customization)
> - [auto-accept plan mode](#feature-auto-accept-plan-mode) (thank you [@irdbl](https://github.com/irdbl)!)
> - [dangerously bypassing permissions in sudo](#feature-bypass-permissions-check-in-sudo) (thank you [@brrock](https://github.com/brrock)!)
> - [native installer warning suppression](#feature-suppress-native-installer-warning) (thank you [@brrock](https://github.com/brrock)!).
With tweakcc, you can
- Customize all of Claude Code's **system prompts** (**NEW:** also see all of [**Claude Code's system prompts**](https://github.com/Piebald-AI/claude-code-system-prompts))
- Create custom **toolsets** that can be used in Claude Code with the new **`/toolset`** command
- **Highlight** custom patterns while you type in the CC input box with custom colors and styling, like how `ultrathink` used to be rainbow-highlighted.
- Manually name **sessions** in Claude Code with `/title my chat name` or `/rename` (see [**our blog post**](https://piebald.ai/blog/messages-as-commits-claude-codes-git-like-dag-of-conversations) for implementation details)
- Create **custom themes** with a graphical HSL/RGB color picker
- Add custom **thinking verbs** that will show while Claude's working
- Create custom **thinking spinner animations** with different speeds and phases
- Style the **user messages in the chat history** beyond the default plain gray text
- Remove the **ASCII border** from the input box
- Expand **thinking blocks** by default, so that you don't need to use the transcript (Ctrl+O) to see them
- Configure which Claude **model** each **subagent** (Plan, Explore, and general-purpose) uses
- Switch between **table formats** - Claude Code default, Unicode (`┌─┬─┐`), ASCII/markdown (`|---|`), Unicode without top/bottom borders.
tweakcc also
- Fixes a bug where the **spinner animation** is frozen if you have the `CLAUDE_CODE_DISABLE_NONESSENTIAL_TRAFFIC` environment variable set ([#46](https://github.com/Piebald-AI/tweakcc/issues/46))
- Allows you to **change the context limit** (default: 200k tokens) used with models from custom Anthropic-compatible APIs with a new environment variable, `CLAUDE_CODE_CONTEXT_LIMIT`
- Adds the **`opusplan[1m]`** model alias, combining Opus for planning with Sonnet's 1M context for execution—reducing "[context anxiety](#feature-opus-plan-1m-mode)" ([#108](https://github.com/Piebald-AI/tweakcc/issues/108))
- Adds a message to Claude Code's startup banner indicating that you're running the patched version of CC (configurable)
- Speeds up Claude Code startup by **~50%** with non-blocking MCP connections and configurable parallel connection batch size ([#406](https://github.com/Piebald-AI/tweakcc/issues/406))
tweakcc supports Claude Code installed on **Windows, macOS, and Linux**, both **native/binary installations** and those installed via npm, yarn, pnpm, bun, Homebrew/Linuxbrew, nvm, fnm, n, volta, nvs, nodenv, and **Nix** (including [NixOS](https://nixos.org/) and [nix-darwin](https://github.com/LnL7/nix-darwin)), as well as custom locations.
tweakcc supports Claude Code's **native installation**, which is a large platform-specific [Bun](https://github.com/oven-sh/bun) executable. Current Claude Code releases store the application as a graph of code-split JavaScript modules rather than one embedded `cli.js`; tweakcc discovers and updates the owning modules while preserving Bun's compiled graph layout. We support patching the native binary on macOS, Windows, and Linux, including ad-hoc signing on Apple Silicon, via [**node-lief**](https://github.com/Piebald-AI/node-lief), our Node.js bindings for [LIEF (Library to Instrument Executables)](https://github.com/lief-project/LIEF).
While tweakcc has a large library of built-in patches, you can create custom patches by using tweakcc's [API](#api). If you don't want to create an npm package, you can use [`tweakcc adhoc-patch`](#cli-commands), which applies a custom Node.js script to your default Claude Code installation. Because `adhoc-patch` supports running scripts from an HTTP URL, you can even host a script on a GitHub Gist or pastebin for easy distribution.
Run without installation:
```bash
$ npx tweakcc
# Or use pnpm:
$ pnpm dlx tweakcc
```
## Table of contents
- [How it works](#how-it-works)
- [Remote config](#remote-config)
- [CLI Commands (`unpack`, `repack`, `adhoc-patch`)](#cli-commands)
- [API](#api)
- [System prompts](#system-prompts)
- [Toolsets](#toolsets)
- [**Features**](#features)
- [System prompts](#system-prompts)
- Themes
- Thinking verbs customization
- Thinking indicator customizations
- Context limit
- LSP support
- Hide "ctrl-g to edit prompt in <editor>"
- Hide the startup banner
- Hide the startup "Clawd" logo
- Increase the max size in tokens for files read via `Read`
- Remove the border from the message input box
- Add all models to `/model`
- tweakcc patches applied indicator
- Show more items in select menus
- Subagent models
- Suppression of `1→ ` prefixes from `Read` output
- Suppress `/rate-limit-options` from being injected
- Swarm mode
- Session memory
- `/remember` skill
- [Toolsets](#toolsets)
- User message display customization
- Token indicator display
- [Add support for dangerously bypassing permissions in sudo](#feature-bypass-permissions-check-in-sudo)
- [Input pattern highlighters](#feature-input-pattern-highlighters)
- [Opus Plan 1M mode](#feature-opus-plan-1m-mode)
- [MCP startup optimization](#feature-mcp-startup-optimization)
- [Table format](#feature-table-format)
- [Token count rounding](#feature-token-count-rounding)
- [Statusline update customization](#feature-statusline-update-customization)
- [AGENTS.md support (with video)](#feature-agentsmd-support)
- [Auto-accept plan mode](#feature-auto-accept-plan-mode)
- [Suppress native installer warning](#feature-suppress-native-installer-warning)
- [Scroll escape sequence filter](#feature-scroll-escape-sequence-filter)
- [WebFetch User-Agent](#feature-webfetch-user-agent)
- [Disable Ctrl-Z suspend](#feature-disable-ctrl-z-suspend)
- [Skip shell permission check in your skills/commands](#feature-skip-shell-permission-check-in-your-skillscommands)
- [Shimmer style](#feature-shimmer-style)
- [Input cursor color](#feature-input-cursor-color)
- [`/plan exit`](#feature-plan-exit)
- [tmux graphics passthrough](#feature-tmux-graphics-passthrough)
- [Skip startup dialogs](#feature-skip-startup-dialogs)
- _Missing documentation for above features coming soon_
- [Configuration directory](#configuration-directory)
- [Building from source](#building-from-source)
- [Troubleshooting](#troubleshooting)
- [FAQ](#faq)
- [Contributing](#contributing)
- [Related projects](#related-projects)
- [License](#license)
## How it works
tweakcc works by patching Claude Code's minified `cli.js` file, reading customizations from `~/.tweakcc/config.json`. For npm-based installations `cli.js` is modified directly, but for native installations it's extracted from the binary using [node-lief](https://github.com/Piebald-AI/node-lief), patched, and then the binary is repacked. When you update your Claude Code installation, your customizations will be overwritten, but they're remembered in your configuration file, so they can be reapplied by just running `npx tweakcc --apply` (you'll see a pre-apply summary and be asked to confirm; use `--yes` / `-y` to skip the prompt in scripts).
tweakcc is verified to work with Claude Code **2.1.162.** In newer or earlier versions various patches might not work. However, if we have the [system prompts for your version](https://github.com/Piebald-AI/tweakcc/tree/main/data/prompts) then system prompt patching is guaranteed to work with that version, even if it's significantly different from the verified CC version—the version number stated above is only relevant for the non-system-prompt patches. We get the latest system prompts within minutes of each new CC release, so unless you're using a CC version older than 2.0.14, your version is supported.
You can also create custom patches using tweakcc without having to fork it or open a PR. [`tweakcc adhoc-patch`](#cli-commands) supports using custom scripts that work with native and npm-based installs and that automatically detect your Claude Code installation.
## Remote Config
While tweakcc usually works by applying customizations from your local `~/.tweakcc/config.json`, you can optionally pass the `--config-url --apply and --patchesunpackrepackadhoc-patch