C odeBricks

C odeBricks

Xcode and the Claude API

2025-11-18

Add your Claude API Key to Xcode 


Once you have the latest and greatest Xcode installed on your Mac, and Apple Intelligence enabled in System Settings, it’s time to open Xcode Settings. Add in Xcode Settings your Claude API key, as shown in the two pictures. Vibe coding can begin. Step by step: 


1. Click on the “Add a Model Provider … “ button;

2. Fill in the Anthropic endpoint information as shown in the second picture. 


In Xcode you will be able to toggle - on the left side of the Xcode IDE - between the File Navigator and the AI Agent conversation window. I like conversations with Claude Sonnet 4.5 ,  it is my favorite model. 


Happy vibe coding! 


P.S. The pricing of the API key is “pay-as-you-go”. To generate your API key make an account at console.anthropic.com The cost control settings are very good. Typical monthly cost: 5 to 55 USD. 

^