OpenID Connect explained: login on top of OAuth 2.0
OpenID Connect (OIDC) lets an app verify who you are via a provider like Google. Learn the flow, the ID token, the risks and OIDC's place beside the EU wallet.
StandardsPublished
OpenID Connect (OIDC) is a standard that lets an application find out who a user is by asking a provider the user already trusts, such as a company directory, Google or a national login service. The user signs in at the provider, and the provider tells the application the result in a signed message. The application never handles the user’s password.
What OpenID Connect is for
Before OIDC, every website kept its own list of usernames and passwords. That meant dozens of passwords, dozens of databases to leak, and dozens of account recovery processes. OIDC moves the login to one place, the OpenID Provider, and lets many applications, called relying parties, rely on it. The same idea powers single sign-on at work and the social login buttons on consumer sites.
OIDC is deliberately small. It adds one thing to OAuth 2.0: a standard way to say “this user was authenticated, here is who they are”. OAuth 2.0 alone only grants access to resources and says nothing about identity. The difference is the subject of OpenID vs OAuth.
Where it comes from
The first OpenID appeared in 2005, and OpenID Authentication 2.0 was approved in December 2007. It was elegant but hard for ordinary users and developers, and big platforms went their own way with proprietary social logins. The OpenID Foundation published OpenID Connect 1.0 in February 2014, built on OAuth 2.0 and JSON Web Tokens, and it became the successor. The story is told in From OpenID to OpenID Connect, and the original protocol is described in OpenID 2.0.
The roles
| Role | What it does | Everyday example |
|---|---|---|
| End user | Person who wants to sign in | You |
| Relying party (RP) | The app that wants to know who you are | A news site, a company intranet |
| OpenID Provider (OP) | Authenticates you and issues tokens | Your employer’s login, Google, a national eID portal |
More background on the app side is in What is a relying party?.
How a login works, step by step
The recommended path is the authorisation code flow, protected by PKCE.
- You click “Sign in” in the app. The app redirects your browser to the provider and asks for the
openidscope, usually withprofileoremail. - The provider authenticates you with whatever method it offers: password, passkey, hardware key, or a mobile eID.
- The provider asks whether you agree to share the requested data with this app.
- The provider redirects you back to the app with a short-lived authorisation code.
- The app, from its server, exchanges the code at the provider’s token endpoint and receives an ID token and an access token.
- The app validates the ID token and creates a session for you. If it needs more data, it can call the UserInfo endpoint.
A simplified authorisation request looks like this:
GET /authorize?response_type=code
&client_id=shop-app
&redirect_uri=https://shop.example/callback
&scope=openid%20email
&state=af0ifjsldkj
&nonce=n-0S6_WzA2Mj
&code_challenge=E9Melhoa2OwvFrEMTJguCHaoeK1t8URWbuGJSstw-cM
&code_challenge_method=S256
The ID token
The ID token is a JSON Web Token (JWT, RFC 7519) signed by the provider. Its payload carries a few standard claims:
{
"iss": "https://login.example.org",
"sub": "248289761001",
"aud": "shop-app",
"exp": 1790000000,
"iat": 1789996400,
"nonce": "n-0S6_WzA2Mj"
}
iss names the provider, sub is a stable identifier for the user at that provider, aud names the app the token is meant for, and nonce ties the token to the original request. The app must check the signature, the issuer, the audience and the expiry before it trusts the token.
Everyday examples
- A university login that works for the library, the learning platform and the mail service.
- A company that lets staff open dozens of cloud tools after one sign-in.
- A shop that offers “Continue with Google” or “Sign in with Apple” (see sign in with Google or Apple).
- A national or municipal portal that accepts a state eID by acting as an OpenID Provider.
Security aspects
- Use the code flow with PKCE. The old implicit flow, which returned tokens in the browser URL, is discouraged in current security guidance such as RFC 9700.
- Check
stateandnonce. They protect against cross-site request forgery and token replay. - Match the redirect URI exactly. Loose matching lets attackers steal codes.
- Validate the token fully. Signature,
iss,aud,expandnonceall matter. - Privacy. The provider learns every app you sign in to. That is the price of centralised login, and a point where the EU wallet’s design differs.
- Provider as single point of failure. If the provider account is lost or compromised, every connected app is affected. Strong sign-in at the provider, ideally a passkey, matters most.
Typical setup mistakes
In practice OIDC integrations rarely fail because of the protocol itself. They fail on small things: a redirect URI that differs by a trailing slash, an unchecked audience in the token, signing keys of the provider that were rotated, or server clocks that are off by minutes. Checking these four points solves most problems quickly.
Status and versions
OpenID Connect Core 1.0 was approved in February 2014 and has since been maintained through corrections (“errata”). The family also includes Discovery (a .well-known/openid-configuration document), Dynamic Client Registration, and logout specifications. All are listed at openid.net/specs. The OpenID Foundation runs a certification programme for implementations. There is no “OIDC 2.0” announced as a replacement; the surrounding OAuth framework is being consolidated as OAuth 2.1, which is still a draft as of October 2026.
How it relates to the other standards
OIDC builds on OAuth 2.0. In large organisations it often runs next to SAML, the older XML-based enterprise standard that solves a similar login problem. The newer OpenID4VP and OpenID4VCI protocols for digital wallets share the OAuth and JWT foundation but solve a different problem: presenting and issuing credentials rather than logging in.
Role in the EUDI Wallet
The EU Digital Identity Wallet is not an OpenID Provider in the classic sense. Its credentials are issued with OpenID4VCI and shown with OpenID4VP, not delivered as ID tokens. OIDC remains relevant around it: many online services will keep OIDC for their own accounts and may put a wallet login in front of an OIDC provider, so users meet both worlds.
Frequently asked questions
Is OpenID Connect the same as OpenID?
No. OpenID Connect is a different protocol from the older OpenID 2.0, even though the name and the idea are related. OIDC is built on OAuth 2.0 and uses JSON and JWTs, while OpenID 2.0 used its own message format and discovery. OpenID 2.0 is effectively retired.
Does OpenID Connect store my password at the app?
No. You enter your password, passkey or other credential only at the provider. The app receives a signed ID token and never sees your password.
Is a login with OpenID Connect the same as proving my legal identity?
No. OIDC proves that you control an account at a provider. Whether that account is tied to a verified person depends on how the provider registered you. For legally binding identity in the EU, eID schemes and the EUDI Wallet are designed for that job.
Who maintains OpenID Connect?
The OpenID Foundation publishes the specifications at openid.net/specs. openideurope.eu is an independent guide and has no connection to the Foundation.
More in Standards
Decentralized identifiers (DIDs): what they are and do
A DID is a W3C identifier you control without a central registry. How DID documents work, how they relate to credentials, and their role in the EUDI Wallet.
FIDO2 and WebAuthn explained: the standards behind passkeys
FIDO2 combines WebAuthn and CTAP to replace passwords with phishing-resistant key pairs. How login works, what WebAuthn Level 3 adds and its EU wallet link.
Identity federation explained: one login, many services
Identity federation lets one trusted provider vouch for you across many services. How it works, the standards it uses, and how the EUDI Wallet changes it.
mdoc and ISO 18013-5: how mobile IDs work
mdoc is the ISO format behind mobile driving licences and one of two EUDI Wallet formats. How ISO 18013-5 and 18013-7 work, and what stays private.
OpenID4VCI explained: how credentials get into a wallet
OpenID for Verifiable Credential Issuance (OpenID4VCI) 1.0 brings credentials from issuers into a wallet. Roles, flow, security and its place in the EU wallet.
OpenID4VP explained: how a wallet presents credentials
OpenID for Verifiable Presentations (OpenID4VP) 1.0 is the protocol a wallet uses to show credentials to a service. Flow, roles, security and EU wallet role.