OAuth Flow Tester

Test OAuth2 / OpenID Connect flows with PKCE against any provider. This tool runs entirely in your browser.

1Configure Provider

Issuer base: Enter the issuer base URL (e.g. https://auth.example.com) — we fetch from /.well-known/openid-configuration by default.
Full URL: Or paste the full discovery document URL if your provider uses a different path (e.g. /.well-known/oauth-authorization-server). We use whatever URL you provide as-is.
Discovery Document (JSON)

                        

2Add Callback URL to Your Provider

Add the following URL as an allowed Redirect URI / Callback URL in your OAuth provider's application settings:

3Parameters editable

Default: openid profile email. Change if your app needs different scopes.

4Start OAuth Flow

The flow will open in a new tab. Complete authentication there; results will appear in that tab.

Result

User
ID Token Claims

                        
UserInfo Response

                        
Tokens
Full Token Response

                    

Understanding the authorization code flow

The exchange, step by step

Your app redirects the user to the authorization server's /authorize endpoint with client_id, redirect_uri, response_type=code, scope, state, and a PKCE challenge. The user authenticates there — your application never sees their credentials, which is the entire point of the flow.

On success the server redirects back to your redirect_uri with a short-lived code and your state echoed back. Your app verifies the state matches, then POSTs the code plus the PKCE verifier to /token and receives an access token, usually an ID token, and often a refresh token.

Where flows break

By far the most common failure is redirect_uri_mismatch, which is exact string comparison and fails on a trailing slash, a port, or a case difference in the path. Second is an invalid or missing state, usually because it wasn't persisted across the redirect. Third is the code expiring — authorization codes typically live 30 to 60 seconds and are single-use.

A subtler one: reusing an authorization code. Codes are one-shot, and a well-behaved server will revoke the tokens it already issued if a code is presented twice, on the assumption the code leaked. Double-submitting a callback handler is enough to trigger this.

Implicit flow is deprecated

The implicit flow (response_type=token) returned tokens directly in the URL fragment, with no code exchange. It exists because CORS support was once unreliable, and it leaks tokens into browser history, referrer headers, and server logs.

It is deprecated in the OAuth 2.0 Security Best Current Practice and removed in OAuth 2.1. Use the authorization code flow with PKCE for browser and mobile clients — it is what every current SDK does by default.

Frequently asked questions

The authorization code is a short-lived, single-use reference returned via the browser redirect. It is not a credential for any API. You exchange it server-to-server (or with PKCE from a public client) for the access token, which is what you actually send to APIs. Splitting them keeps the access token out of the URL.

Codes are deliberately short-lived, typically 30 to 60 seconds. If your exchange takes longer, the usual causes are a slow callback handler, a manual copy-paste while debugging, or a retry after a failed first attempt. Exchange the code immediately on receipt.

No, and you shouldn't have one. Anything shipped to a browser is public. SPAs are public clients: use the authorization code flow with PKCE and no secret. PKCE provides the protection the secret would otherwise be doing.

Only what you need. Request openid to get an ID token under OIDC, plus profile or email if you need those claims, plus any API-specific scopes. Over-requesting shows the user a heavier consent screen and widens the blast radius if a token leaks.

Yes — enter any provider's authorization and token endpoints, or fetch them automatically from a discovery document with the OIDC Discovery tool. You'll need to register this page's callback URL with that provider first.

Testing against someone else's provider?

Point it at your own. Register an application, get real client credentials, and run this flow end to end in a few minutes.

Free, unlimited users. No credit card required.