[BUG] Claude Agent in Xcode downloads ARM64 binary on Intel Macs, x64 binary rejected due to code signing

Resolved 💬 4 comments Opened Mar 29, 2026 by JamesEvans777 Closed May 2, 2026

Preflight Checklist

  • [x] I have searched existing issues and this hasn't been reported yet
  • [x] This is a single bug report (please file separate reports for different bugs)
  • [x] I am using the latest version of Claude Code

What's Wrong?

On Intel Macs, Xcode downloads the darwin-arm64 binary for the Claude Agent, which cannot execute on x86_64 hardware. The binary fails silently and returns a 401 Invalid Bearer Token error in Xcode's Intelligence settings, even with valid Pro account credentials and a working API key. Claude chat within Xcode works fine, as it communicates directly with Anthropic's API. Only the Claude Agent/coding intelligence features are affected.
Manually downloading the correct darwin-x64 binary and placing it in the agent directory fails with:

"Failed to initialize Claude Agent: The code signing identity for the agent did not match expectations, or the agent violated sandboxing rules."

This means Intel Mac users cannot use the Claude Agent in Xcode at all, regardless of plan or credentials.

What Should Happen?

Xcode should detect the host Mac architecture before downloading the Claude Agent binary. On an Intel Mac it should request the darwin-x64 binary. On Apple Silicon it should request darwin-arm64. Alternatively, Anthropic could ship a universal binary containing both architectures which would work on any Mac regardless of CPU.

After a fix, the expected behaviour is:

  1. Click Get in Xcode Intelligence settings
  2. Xcode downloads the correct binary for the host CPU
  3. Sign in with Claude Pro account or API key
  4. Green status indicator appears next to Claude Agent
  5. Coding intelligence and agentic coding features work correctly

Error Messages/Logs

401 Invalid Bearer Token (shown in Xcode Intelligence settings after signing in)

Failed to initialize Claude Agent: The code signing identity for the agent did not match expectations, or the agent violated sandboxing rules. Please delete the currently selected agent in the Components section of Settings and download it again.

Terminal confirmation of wrong architecture:
$ file ~/Library/Developer/Xcode/CodingAssistant/Agents/claude/2.1.14/claude
Mach-O 64-bit executable arm64

$ defaults read com.apple.dt.Xcode IDEChatClaudeCodeVersion
{"url":"https://storage.googleapis.com/claude-code-dist-86c565f3-f756-42ad-8dfa-d59b1c096819/claude-code-releases/2.1.14/darwin-arm64/claude","version":"2.1.14","checksum":"e0b46113b66a91db787e01bca0f5baa262ce4308852baf8a2d32ea504053fd11ab31c0ac5ccc88800d7a6c633ccd26ef003261ac5005b1c448fbaf307310cf71"}

Steps to Reproduce

  1. On an Intel Mac running macOS 26.3, open Xcode 26.3
  2. Go to Settings → Intelligence → Anthropic
  3. Click Get to download the Claude Agent
  4. Sign in with a valid Claude Pro account or API key
  5. Attempt to use any coding intelligence or agent feature

Result: 401 Invalid Bearer Token error. Claude chat works fine but all coding intelligence features fail.

Claude Model

Sonnet (default)

Is this a regression?

I don't know

Last Working Version

_No response_

Claude Code Version

2.1.14 (Claude Code) - terminal version works correctly on Intel

Platform

Anthropic API

Operating System

macOS

Terminal/Shell

Terminal.app (macOS)

Additional Information

Full investigation performed:

  1. Cleared all keychain entries for Claude and Anthropic - no effect
  2. Cleared all Xcode defaults related to Claude - no effect
  3. Deleted and re-downloaded Claude Agent multiple times - no effect
  4. Confirmed darwin-x64 binary exists in Anthropic's distribution bucket and runs correctly on this Intel Mac:

$ curl -fsSL -o /tmp/claude-x64 "https://storage.googleapis.com/claude-code-dist-86c565f3-f756-42ad-8dfa-d59b1c096819/claude-code-releases/2.1.14/darwin-x64/claude"
$ /tmp/claude-x64 --version
2.1.14 (Claude Code)

  1. Manifest confirms x64 binary exists with correct checksum:

darwin-x64 checksum: 0b44e49b28755dc3e42e7bdd20e9a91da79c78b1bd216141f06f96792d31b23c
darwin-x64 size: 184243008

  1. Manually updated IDEChatClaudeCodeVersion to point to darwin-x64 URL - Xcode downloaded the correct binary but rejected it with code signing error, meaning the code signing verification is also architecture-specific.

The 401 error is misleading - it is not a credentials problem. It is caused by Xcode running an ARM64 binary on an Intel CPU which fails silently and surfaces as an authentication error. All credentials and account settings are valid as confirmed by Claude chat working correctly in Xcode.

View original on GitHub ↗

This issue has 4 comments on GitHub. Read the full discussion on GitHub ↗