---
title: "Build \"Sign in with Your App\" using Supabase Auth"
description: "Supabase Auth can now act as an OAuth 2.1 and OpenID Connect identity provider, letting a project offer \"Sign in with [Your App]\" to third-party apps, MCP-based AI agents, partner integrations and enterprise SSO."
url: "https://swe.quest/articles/build-sign-in-with-your-app-using-supabase-auth-a42222eedce43362"
canonical: "https://supabase.com/blog/oauth2-provider"
source: "Supabase"
published: "2025-12-04"
difficulty: "medium"
kind: "Announcement"
reading_minutes: 6
tags: ["identity-auth","ai-agents","postgres"]
---

# Build "Sign in with Your App" using Supabase Auth

A post on [Supabase](https://swe.quest/sources/supabase.md), published 2025-12-04, 6 min read, Announcement. Original: [https://supabase.com/blog/oauth2-provider](https://supabase.com/blog/oauth2-provider)

## Summary

Supabase Auth can now act as an OAuth 2.1 and OpenID Connect identity provider, letting a project offer "Sign in with \[Your App\]" to third-party apps, MCP-based AI agents, partner integrations and enterprise SSO. It uses the authorization code flow with PKCE, issues JWT access tokens carrying a client\_id claim alongside the usual user\_id and role, and also provides ID tokens, a UserInfo endpoint, refresh tokens, a JWKS endpoint and discovery documents at /.well-known/oauth-authorization-server and /.well-known/openid-configuration. MCP clients can register themselves through dynamic client registration. Existing login methods, Custom Access Token Hooks and Row Level Security all apply to OAuth tokens, so RLS policies can limit each client to specific data by checking the client\_id claim. Granular scopes are planned but not yet available.

Written by swe.quest, not by the author.

**Difficulty:** Medium: assumes a working developer; shows how it is built or done

## Topics

- [Identity & auth](https://swe.quest/tags/identity-auth.md) (Security)
- [AI agents](https://swe.quest/tags/ai-agents.md) (AI & ML)
- [PostgreSQL](https://swe.quest/tags/postgres.md) (Data & databases)

## Prerequisites

- OAuth 2.0 basics ([easy posts on Identity & auth](https://swe.quest/tags/identity-auth.md?difficulty=easy))
- JWTs
- Postgres Row Level Security ([easy posts on PostgreSQL](https://swe.quest/tags/postgres.md?difficulty=easy))

## Keywords

Supabase Auth, OAuth 2.1, OpenID Connect, PKCE, Model Context Protocol, Row Level Security, JWKS

## Related posts

- [Custom OIDC Providers for Supabase Auth](https://swe.quest/articles/custom-oidc-providers-for-supabase-auth-f58ec95541f5b5f1.md): Supabase · 2026-04-08 · Medium · 4 min read · Identity & auth
  Supabase Auth now supports connecting any standards-compliant OpenID Connect identity provider, beyond its 20+ built-in social logins, for cases like regional compliance IdPs, self-hosted GitHub Enterprise or GitLab, and niche SSO systems.
- [Supabase Auth: SSO, Mobile, and Server-side support](https://swe.quest/articles/supabase-auth-sso-mobile-and-server-side-support-6a2bc9b0f4a5ef26.md): Supabase · 2023-04-13 · Medium · 7 min read · Identity & auth, PostgreSQL, Multi-tenancy, Mobile
  Supabase Auth adds SAML 2.0 single sign-on, a PKCE authorization flow for server-side rendering and mobile apps, and native Sign in with Apple on iOS.
- [Give your Supabase app its own MCP server](https://swe.quest/articles/give-your-supabase-app-its-own-mcp-server-db89f29412fb7983.md): Supabase · 2026-10-22 · Medium · 5 min read · AI agents, Identity & auth, PostgreSQL, Serverless, TypeScript
  Supabase apps can expose their own MCP server so customers use the app from ChatGPT, Claude or other MCP clients, signed in with their existing account.
- [Managed Better Auth is now an OAuth provider, with MCP support](https://swe.quest/articles/managed-better-auth-is-now-an-oauth-provider-with-mcp-support-613f00a7521407ac.md): Neon · 2026-11-02 · Medium · 5 min read · Identity & auth, AI agents, PostgreSQL
  Neon's Managed Better Auth now supports the OAuth Provider plugin, turning an auth instance into an OAuth 2.1 authorization server that both companion apps and MCP clients can use to sign users in.
- [Enterprise-managed auth for MCP: Claude can now issue the identity assertion](https://swe.quest/articles/enterprise-managed-auth-for-mcp-claude-can-now-issue-the-identity-assertion-aa52985ca7fe5bc7.md): Supabase · 2026-11-03 · Medium · 3 min read · Identity & auth, AI agents
  Claude can now act as the issuer of the signed ID-JAG (Identity Assertion JWT Authorization Grant) for the Supabase MCP server, enabling enterprise-managed authorization for organizations whose identity provider doesn't support the MCP Enterprise-Managed Authorization extension (previously effectively only Okta).

Browse: [Latest posts](https://swe.quest/index.md) · [Topics](https://swe.quest/tags.md) · [Sources](https://swe.quest/sources.md) · [Topic map](https://swe.quest/map.md) · [Site guide (llms.txt)](https://swe.quest/llms.txt)
