PaPoo
cover

Claude Code で HTTP 403 が出るときに見るべきところ

まず、この HTTP 403 がどこから返ってきているかで話が変わります。今回の症状クラスタに入っている issue は、どちらも「対象サイト側の拒否」ではなく、Claude Code 側の egress proxy が弾いているように見える報告でした。[#34690](https://github.com/anthropics/claude-code/issues/34690) では x-deny-reason: host_not_allowed が見え、[#85330](https://github.com/anthropics/claude-code/issues/85330) では auto mode classifier によるブロックが繰り返し起きています。

筆者の環境で claude doctor を見ると、少なくともインストール状態そのものは致命的には壊れていませんでした。ただし、Multiple installations foundLeftover npm global installation の警告は出ています。これは今回の HTTP 403 の直接原因だとは断定できませんが、環境に複数の Claude Code が混在していることは分かります。

$ claude doctor
Claude Code doctor

Running: native (2.1.207)
Commit: bc512d563325
Platform: darwin-arm64
Path: ~/.local/share/claude/versions/2.1.207
Config install method: native
Search: OK (bundled)
Auto-updates: enabled
Auto-update channel: latest
Last update attempt: none recorded

Multiple installations found
- npm-global at /usr/local/bin/claude
- native at ~/.local/bin/claude

Remote Control
Control this session from claude.ai/code or the Claude mobile app

1 warning found
- Leftover npm global installation at /usr/local/bin/claude
  Fix: Run: npm -g uninstall @anthropic-ai/claude-code

[#34690](https://github.com/anthropics/claude-code/issues/34690) の報告で重要なのは、設定で Allow network egress を有効にし、​Domain allowlistAll domains にしていても、実際には広く許可されず、proxy が固定の allowlist を使っているように見える点です。報告者は curl -v で見える https_proxy JWT に allowed_hosts が明示されており、All domains の設定がそのトークンに反映されていないと書いています。つまり、UI や設定上は「全部許可」に見えても、実際の通信では 403 になるケースがある、ということです。

[#85330](https://github.com/anthropics/claude-code/issues/85330) では別の形で、mcp__claude-in-chrome__navigate が「Claude Code auto mode classifier」によって拒否され続けています。しかも同じ URL を何度試しても結果が変わらず、ユーザーが明示的に bypass を指示しても、セッション側で Exited Plan ModeExited Auto Mode のような遷移が挟まった、という報告でした。こちらはネットワークの 403 というより、実行ポリシー側で止められているケースです。

今回の 403 がどちら寄りかを見分けるには、エラーの出方を見るのが早いです。x-deny-reason: host_not_allowed のような文言があるなら、[#34690](https://github.com/anthropics/claude-code/issues/34690) に近いです。もし「permission denied by the Claude Code auto mode classifier」のようなメッセージなら、[#85330](https://github.com/anthropics/claude-code/issues/85330) に近いです。

issue コメントには、さらに切り分けのヒントがあります。たとえば GitHub では github.com は通るのに raw.githubusercontent.comapi.github.com が落ちる、という観察がありました。これは、もし allowlist がワイルドカードではなく個別ホスト名で扱われているなら説明がつく、という話です。ただし、これはコメント上の観察であって、筆者が同条件で再現したものではありません。

現時点で、確認できていることだけを並べるとこうなります。

- 403 は Claude Code の egress proxy か auto mode classifier で出ている可能性がある
- issue #34690 では allow network egress + All domains でも host_not_allowed の 403 が出る
- issue #85330 では browser navigation が auto mode classifier によって繰り返し拒否される
- 筆者の環境では claude doctor に multiple installations found の警告が出た

ここから先は、解決策として確立しているとは言えません。少なくとも今回の issue 群だけを見る限り、「設定を All domains にしたのに 403 になる」こと自体が報告されており、ユーザー側の誤設定だけで片づけられない症状です。もし同じ HTTP 403 を見ていて、エラー文に host_not_allowed や classifier の文言が含まれるなら、まずはその文字列を控えたうえで issue #34690 / #85330 と照合するのがよさそうです。


検証環境

claude --version : 2.1.207 (Claude Code)
OS          : Darwin 25.3.0 (arm64)
Python      : 3.14.2
検証日時    : 2026-08-10T12:36:45+09:00

参照した Issue(anthropics/claude-code): #34690, #85330

同じ著者の記事