Xcode 26.6 and 27 Gemini Authentication with Configuration Files

I’m attempting to set up Gemini agentic support in Xcode 26.6 RC (and I'm assuming the process is the same in 27), but since I need to use Gemini with a corporate account, I have a Google Cloud Project ID, not an API key, so it seems like the configuration file route is the right path?

After consulting Gemini and filling out the .env file and settings.json files, Xcode is complaining about needing to be authenticated, and I can’t seem to see how to trigger the auth, like one might do in Gemini CLI.

I'd appreciate any suggestions or advice at this point.

Thanks in advance!

Hello @InteractiveLogic!

Given your intended Google Cloud Project configuration, selecting "Authenticate with Configuration Files..." in Settings → Intelligence → Gemini → Account should point Xcode to your Google Cloud environment values in your .env file.

Two things worth noting:

  • Xcode uses a separate directory to manage the Gemini integration to avoid overriding your existing setup. To point both Xcode and Gemini at your .env and settings.json files, they should both be placed within ~/Library/Developer/Xcode/CodingAssistant/gemini/.gemini. Xcode manages everything within the gemini directory, while the agent itself manages the gemini/.gemini subdirectory.
  • You will need to provide a GOOGLE_CLOUD_PROJECT and GOOGLE_CLOUD_LOCATION within your .env file.

If these steps don't work for you, or if you've already tried them, please let me know and we can work from there!

Hi @devingreen - I've attempted those steps in that location already and I'm wondering if I'm missing some other steps to get Gemini authenticated?

Should I be running an instance of Gemini-CLI, or is there some pre-configuration steps in Terminal that I should be doing to kickstart Gemini to open a browser window to authenticate me for my Enterprise credentials?

Xcode 26.6 and 27 Gemini Authentication with Configuration Files
 
 
Q