Answer: Add `forceLoginMethod` and `forceLoginGatewayUrl` to your own user settings file, `~/.claude/settings.json`, which requires Claude Code v2.1.295 or later. Set `forceLoginMethod` to "gateway" and `forceLoginGatewayUrl` to your gateway URL. Status: Confirmed Entry: tool/claude-code/admin-and-enterprise/set-gateway-url-user-settings Revision: 3 Digest: sha256:0918d7527e29d751 (changes whenever the content changes) Timeline: Created: 2026-11-13T03:03:31Z Last changed: 2026-11-19T12:14:28Z (scope: User settings only → —) Last verified: 2026-11-20T12:18:47Z Next check: 2026-11-21T12:18:47Z Check interval: Daily Expected change: No fixed schedule Data: Field | Value | Source | As of settings file | ~/.claude/settings.json | [1] | 2026-11-20 required version | v2.1.295 | [1] | 2026-11-20 forceLoginMethod value | gateway | [1] | 2026-11-20 forceLoginGatewayUrl example | https://claude-gateway.internal.example.com | [1] | 2026-11-20 Sources: [1] Anthropic. "Claude apps gateway for Amazon Bedrock, Claude Platform on AWS, Google Cloud, and Microsoft Foundry". https://code.claude.com/docs/en/claude-apps-gateway.md Role: primary. Accessed: 2026-11-20T12:18:47Z Quote: "add `forceLoginMethod` and `forceLoginGatewayUrl` to their own user settings file, `~/.claude/settings.json`" (Supports: settings file) Quote: "This requires Claude Code v2.1.295 or later on the developer machine." (Supports: required version) Quote: ""forceLoginMethod": "gateway"" (Supports: forceLoginMethod value) Quote: ""forceLoginGatewayUrl": "https://claude-gateway.internal.example.com"" (Supports: forceLoginGatewayUrl example) Published: 2026-11-20T03:58:44Z Snapshot SHA-256: 06445c361c615d85095e3a2d0e9215a0129d7fa2e0ad404284080d8820c506b9 (captured 2026-11-19T12:14:28Z) Verification: Method: Automated extraction from [1] with deepseek-flash (JSON output, thinking disabled). Every value was checked by code to appear verbatim in a quoted passage of [1]. On this check the text of [1] was unchanged since 2026-11-19T12:14:28Z, so the values verified then were kept. Cross-check: not-available at 2026-11-20T12:18:47Z. No independent second source is configured for this entry Last successful check: 2026-11-20T12:18:47Z Last attempt: 2026-11-20T12:18:47Z Notes and limitations: Extracted automatically from a single official source (section "Set the gateway URL in user settings"). Related: https://latestn.com/tool/claude-code/admin-and-enterprise/set-session-memory-limit How do I set a memory limit for each session on a Claude Code self-hosted runner? https://latestn.com/tool/claude-code/admin-and-enterprise/set-spend-cap-admin-api How do I set a spend limit for a developer through the Claude apps gateway Admin API? https://latestn.com/tool/claude-code/admin-and-enterprise/set-team-spend-limits How do I set spend limits for my team in Claude Code? https://latestn.com/tool/claude-code/admin-and-enterprise/server-managed-settings-requirements What plan and role do I need to use server-managed settings in Claude Code? https://latestn.com/tool/claude-code/admin-and-enterprise/session-token-claims-reference What claims does the Claude Code session access token contain and what does each claim mean? https://latestn.com/tool/claude-code/admin-and-enterprise/session-token-proves-and-format What does the Claude Code session token prove and what is its format? https://latestn.com/tool/ All entries in AI tools Change log: Time | Event | Change | Source 2026-11-19T12:14:28Z | changed | scope: User settings only → — | [1] 2026-11-17T12:23:25Z | changed | scope: — → User settings only | [1] 2026-11-17T12:23:25Z | changed | required version: — → v2.1.295 | [1] 2026-11-17T12:23:25Z | changed | minimum version: v2.1.295 → — | [1] 2026-11-13T03:03:31Z | added | Entry created | — Changes for this entry as a feed: https://latestn.com/tool/claude-code/admin-and-enterprise/set-gateway-url-user-settings/latest Challenge this entry: Open challenges: None How: If a value here is wrong or out of date, send what is wrong and a link to evidence. Challenges are queued and checked against the evidence; they do not change the entry by themselves. If the entry changes as a result, the change log says so. Form: https://latestn.com/dispute/tool/claude-code/admin-and-enterprise/set-gateway-url-user-settings POST: https://latestn.com/dispute/tool/claude-code/admin-and-enterprise/set-gateway-url-user-settings with claim, evidence_url, and optionally field and contact (form-encoded or JSON) GET: https://latestn.com/dispute/tool/claude-code/admin-and-enterprise/set-gateway-url-user-settings?claim={what is wrong}&evidence_url={link} How to cite: LatestN. (2026). How do I set the gateway URL for Claude Code in user settings? Revision 3, last verified 2026-11-20T12:18:47Z. https://latestn.com/tool/claude-code/admin-and-enterprise/set-gateway-url-user-settings (accessed 2026-11-21T10:02:40Z). @misc{LatestN_tool_claude_code_admin_and_enterprise_set_gateway_url_user_settings_r3, title = {How do I set the gateway URL for Claude Code in user settings?}, author = {{LatestN}}, year = {2026}, howpublished = {\url{https://latestn.com/tool/claude-code/admin-and-enterprise/set-gateway-url-user-settings}}, note = {Revision 3; digest sha256:0918d7527e29d751; last verified 2026-11-20T12:18:47Z; accessed 2026-11-21T10:02:40Z} } Reuse: License: CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/) Attribution: Copying and adapting are allowed, including commercially, if you credit LatestN and link to the entry you used. Each entry ends with a ready-made citation. URL: https://latestn.com/tool/claude-code/admin-and-enterprise/set-gateway-url-user-settings