Answer: For servers that support OAuth discovery, you can omit the OAuth configuration and let the CLI discover it automatically by specifying only the server's url; alternatively, you can configure an explicit oauth block with enabled, issuer, authorizationUrl, tokenUrl, clientId, and scopes. Gemini CLI supports OAuth 2.0 authentication for remote MCP servers using SSE or HTTP transports. Status: Confirmed Entry: tool/gemini-cli/permissions-and-security/mcp-oauth-authentication Revision: 1 Digest: sha256:10c07dc913c5b9a2 (changes whenever the content changes) Timeline: Created: 2026-11-13T03:19:09Z Last changed: 2026-11-13T03:19:09Z Last verified: 2026-11-20T12:54:10Z Next check: 2026-11-21T12:54:10Z Check interval: Daily Expected change: No fixed schedule Data: Field | Value | Source | As of OAuth version | OAuth 2.0 | [1] | 2026-11-20 Supported transports | SSE or HTTP | [1] | 2026-11-20 Automatic discovery | omit the OAuth configuration | [1] | 2026-11-20 Example discovered server URL | https://api.example.com/sse | [1] | 2026-11-20 Example issuer | https://auth.example.com | [1] | 2026-11-20 Example clientId | gemini-cli-client | [1] | 2026-11-20 Example scopes | ["mcp:read", "mcp:write"] | [1] | 2026-11-20 Management command | /mcp auth | [1] | 2026-11-20 Sources: [1] Google. "MCP servers with Gemini CLI". https://geminicli.com/docs/tools/mcp-server.md Role: primary. Accessed: 2026-11-20T12:54:10Z Quote: "Gemini CLI supports OAuth 2.0 authentication for remote MCP servers using SSE or" (Supports: OAuth version) Quote: "SSE or HTTP transports. This enables secure access to MCP servers that require" (Supports: Supported transports) Quote: "For servers that support OAuth discovery, you can omit the OAuth configuration" (Supports: Automatic discovery) Quote: ""url": "https://api.example.com/sse"" (Supports: Example discovered server URL) Quote: ""issuer": "https://auth.example.com"," (Supports: Example issuer) Quote: ""clientId": "gemini-cli-client"," (Supports: Example clientId) Quote: ""scopes": ["mcp:read", "mcp:write"]" (Supports: Example scopes) Quote: "Use the `/mcp auth` command to manage OAuth authentication:" (Supports: Management command) Published: 2026-10-16T02:36:07Z Snapshot SHA-256: 4aefc4dc30c329cbbd16ca24fe294fb0d91ec87e8f61baca7116c19b6a1a14fd (captured 2026-11-13T03:19:09Z) 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-13T03:19:09Z, so the values verified then were kept. Cross-check: not-available at 2026-11-20T12:54:10Z. No independent second source is configured for this entry Last successful check: 2026-11-20T12:54:10Z Last attempt: 2026-11-20T12:54:10Z Notes and limitations: Extracted automatically from a single official source (section "OAuth support for remote MCP servers"). Related: https://latestn.com/tool/gemini-cli/permissions-and-security/plan-mode-tool-restrictions What tools are restricted in Gemini CLI Plan Mode? https://latestn.com/tool/gemini-cli/permissions-and-security/plan-mode-yolo-availability Is Gemini CLI's enter_plan_mode tool available in YOLO mode? https://latestn.com/tool/gemini-cli/permissions-and-security/proxy-allowed-domains How do I restrict which domains the Gemini CLI sandbox proxy allows? https://latestn.com/tool/gemini-cli/permissions-and-security/enable-trusted-folders How do I enable Trusted Folders in Gemini CLI? https://latestn.com/tool/gemini-cli/permissions-and-security/hook-security-risks What are the security risks of using hooks in Gemini CLI? https://latestn.com/tool/gemini-cli/permissions-and-security/hook-security-risks-2 What are the security risks of using Gemini CLI hooks and how can I mitigate them? https://latestn.com/tool/ All entries in AI tools Change log: Time | Event | Change | Source 2026-11-13T03:19:09Z | added | Entry created | — Changes for this entry as a feed: https://latestn.com/tool/gemini-cli/permissions-and-security/mcp-oauth-authentication/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/gemini-cli/permissions-and-security/mcp-oauth-authentication POST: https://latestn.com/dispute/tool/gemini-cli/permissions-and-security/mcp-oauth-authentication with claim, evidence_url, and optionally field and contact (form-encoded or JSON) GET: https://latestn.com/dispute/tool/gemini-cli/permissions-and-security/mcp-oauth-authentication?claim={what is wrong}&evidence_url={link} How to cite: LatestN. (2026). How do I set up OAuth authentication for a remote MCP server in Gemini CLI? Revision 1, last verified 2026-11-20T12:54:10Z. https://latestn.com/tool/gemini-cli/permissions-and-security/mcp-oauth-authentication (accessed 2026-11-21T10:02:27Z). @misc{LatestN_tool_gemini_cli_permissions_and_security_mcp_oauth_authentication_r1, title = {How do I set up OAuth authentication for a remote MCP server in Gemini CLI?}, author = {{LatestN}}, year = {2026}, howpublished = {\url{https://latestn.com/tool/gemini-cli/permissions-and-security/mcp-oauth-authentication}}, note = {Revision 1; digest sha256:10c07dc913c5b9a2; last verified 2026-11-20T12:54:10Z; accessed 2026-11-21T10:02:27Z} } 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/gemini-cli/permissions-and-security/mcp-oauth-authentication