Skip to content

Cannot detect conversation history and usage statistics? Claude Code

Quick fix

Point the Claude configuration directory to the WSL path; route Claude Code in WSL through the cc-switch gateway for usage statistics.

Error output
WSL使用claudecode的话,是不是windowns下的cc检测不到对话历史and使用统计啊?
English translation

If using claudecode in WSL, can't cc on windowns detect conversation history and usage statistics?

Claude Code conversation history and usage statistics in WSL are written to `~/.claude/` in the WSL file system, while Windows cc-switch reads `~/.claude/` from the Windows file system by default. It therefore cannot detect WSL data by default.

Set the Claude configuration directory to a WSL path to detect conversation history. For usage statistics, enable local routing so Claude Code in WSL goes through the cc-switch gateway; proxy forwarding records usage.

  1. In cc-switch settings, point the Claude configuration directory to the Claude data directory in WSL, for example `\\wsl.localhost\Ubuntu\home\用户名\.claude`.

  2. To collect Claude Code usage in WSL, enable local routing and point `ANTHROPIC_BASE_URL` to the cc-switch proxy address so requests are forwarded through the gateway and usage is recorded.

ToolClaude Code
VersionUnknown
PlatformsWindows

This page is distilled from 1 real issues

If using claudecode in WSL, can't cc on windowns detect conversation history and usage statistics?
Yes, it cannot be detected by default; Windows cc-switch is isolated from the WSL file system. Pointing the Claude configuration directory to the WSL path enables conversation history detection, while usage statistics require routing through the cc-switch gateway.

This is an unofficial community wiki with no affiliation to the cc-switch authors or the project itself. Its content is compiled from the project's public GitHub issues. This site distributes no software.