Skip to content

Types of authentication: passwords, MFA, OAuth, passkeys and SSO explained (2026)

Authentication vs authorization, the most common login methods, where OAuth, OpenID Connect and JWT fit, the new password rules and what AI changed.

Ramon Gomes 17 min read Level: Intermediate

Also available in: Español, Français, Português

Every system I build starts with the same screen: the login. And every time I write that screen, I remember it is both the simplest and the most dangerous part of the project. Simple because the user only types an email and a password. Dangerous because, if it fails, nothing that comes after matters.

This article is the overview I wish I had read when I started: what authentication is, what the types are, where OAuthStandard that lets an app access your data in another service, like Google, without getting your password: you approve and the app receives a limited token., OpenID Connect, JWT and passkey fit in, when to buy and when to build, and what AI changed in all of this. It is a general view. The denser protocols, like OAuth, will get their own articles.

Hotel front desk with a guest showing an ID to the receptionist, who hands over a key card; in the background, room doors and a gym door with a card reader
At the front desk, you show your ID: that is authentication. The card you get opens your room and the gym, but not your neighbor's room: that is authorization.

Authentication, Authorization and Identification: The Three Questions

Think of a hotel front desk. You say your name (identification), show your ID (authentication) and get a card that opens your room and the gym, but not your neighbor's room (authorization). Three different questions: who you claim to be, how you prove it and what you can do.

Software works the same way. The email identifies, the password or the code authenticates, and the system's rules authorize. It sounds like a vocabulary detail, but it is not. In the OWASP Top 10 for 2025, which lists the most common flaws in web applications, broken access control (authorization) is in first place, and authentication failures are in seventh (OWASP). In other words: the most frequent mistake is not letting the attacker in, it is letting someone who is already in see what they should not.

Identification, authentication and authorization in sequence: who you claim to be, how you prove it and what you can do

The Three Factors

Every proof of identity falls into one of three categories:

  • Something you know: password, PIN, secret answer.
  • Something you have: phone, physical USB key, card.
  • Something you are: fingerprint, face, voice.

Multi-factor authentication (MFA) means asking for two or more factors from different categories. Password plus a secret question is not MFA, because both are "something you know". Password plus a code on your phone is. The term 2FA is just the specific case of two factors.

The Most Common Types of Authentication Today

Password

It is the oldest method and still the most common. The problem is not the password itself, it is how it is stored and reused. Have I Been Pwned, the service that collects public breaches, counted more than 17 billion breached accounts in November 2026 (Have I Been Pwned). If a person uses the same password in several places, a breach in any one of them opens all of them. You can check your email at Have I Been Pwned.

On the developer side, a password is never stored as text, but as a hash, a one-way transformation. The current OWASP recommendation is the Argon2id algorithm, with bcrypt left for legacy systems (OWASP Password Storage).

The system sends a one-time code (OTP) or a link that signs you in directly. It takes the password out of the way, which is great for people who sign in rarely. The risk moves to the inbox or the phone number: whoever controls one controls the login. SMS also has the SIM swap problem, which is why it is the weakest of the "something you have" factors.

Authenticator App (TOTP) and Push Notification

Google Authenticator, Microsoft Authenticator, Authy and your own password manager generate a code that changes every 30 seconds (TOTP). It is much safer than SMS. The weak spot is phishing: a fake page asks for the password and the code, and relays both to the real site on the spot.

Social Login

The "Sign in with Google" or "Sign in with Apple" button. The person does not create another password and you do not need to store one. Under the hood, it is OpenID Connect, which I explain further down. The cost is depending on the provider: if the person's Google account gets locked, they lose access to your system too.

Passkey

Passkey is the password replacement that the big vendors adopted together. Instead of a typed secret, the device stores a cryptographic key and unlocks it with your fingerprint, face or phone PIN. The biometrics never leave the device: they only release the local key. And the key only works on the site it was created for, which makes phishing practically useless.

The numbers are what convinced me. In the FIDO Alliance report from October 2026, with data from 15 companies such as Amazon, Google, Microsoft, PayPal and WhatsApp, 36% of successful sign-ins already use passkey, up from 26% in 2025. Passkey sign-in succeeds in 93% of attempts, versus 78% for traditional MFA, and it is almost three times faster (FIDO Alliance). Microsoft measured a 98% success rate with passkey versus 32% with password (Microsoft).

The technical standard behind it is called WebAuthn, and version 3 became an official W3C recommendation in August 2026 (W3C). To see it in practice, WebAuthn.io creates a test passkey on your device, and the Passkeys Directory lists the sites that already accept them.

Corporate SSO

Single sign-on: one login for several of the company's systems. The employee signs in once at the identity provider (Microsoft Entra, Google Workspace, Okta, Keycloak) and the other systems trust it. The two standards are SAML, from 2005, XML-based and still very common in large companies, and OpenID Connect, newer and simpler. If you sell software to companies, supporting SSO is often a contract requirement.

Machine to Machine

When the caller of the APIContract that defines how one program asks another for data or actions: which endpoints to call, what to send and what comes back. On the web, usually HTTP with JSON. is another system, there is no person to type a password. The options are an API key (a fixed secret, simple and easy to leak), OAuth client credentials (the system exchanges credentials for a token that expires) and mTLS (both sides present a certificate). Rule of thumb: an API key never goes into the front-end or into the repository.

Authentication methods ordered by phishing resistance, from SMS to passkey

OAuth 2.0, OpenID Connect and SAML Without the Headache

This is where most of the confusion on the subject lives, including in plenty of articles that rank well on Google.

OAuth 2.0 (RFC 6749, from 2012) solves a delegated authorization problem: letting an app access something of yours in another service without handing over your password. When a calendar app asks to "see and edit your Google Calendar events", that is OAuth. The app gets a token with limited permissions, which expires and can be revoked. Auth0 itself, one of the biggest companies in the field, sums it up: OAuth 2.0 is an authorization protocol, not an authentication one (Auth0).

OpenID Connect (OIDC, from 2014) is the missing layer. It uses the same flow as OAuth, but also returns an ID token saying who the user is. "Sign in with Google" is OIDC.

The flow that works for almost everything today is authorization code with PKCE for users, client credentials for machines and device code for TVs and the command line. OAuth 2.1, which brings all of this into a single specification and removes the old flows, is still a draft at the IETF: the most recent version is from October 31, 2026 (IETF). To see each step of the flow, Okta's OAuth 2.0 Playground shows the requests one by one.

Once the person proves who they are, the system needs to remember that on the next requests. There are two models:

  • Cookie session: the server stores the session and the browser carries only an identifier in a cookie. To sign out, you just delete the session on the server.
  • Token (JWT): the token itself carries the data and a signature. The server does not need to look anything up, which helps when there are many services. The price is revocation: a JWT is valid until it expires, even if the user clicked sign out.

In practice, many applications use both: a short-lived access token and a longer-lived refresh token. To see what is inside a JWT, paste it into JWT.io. Just do not paste a production token into a third-party site.

What Changed in Password Rules

Many companies still follow rules that the reference bodies have dropped. The digital identity guideline from NIST, the United States standards institute, had its final revision published in July 2025 (SP 800-63B-4) and was blunt (NIST):

  • Requiring periodic password changes is forbidden. You only change it when there is a sign that it leaked.
  • Imposing composition rules is forbidden, such as "one uppercase letter, one number and one symbol". They produce predictable passwords like Password@2026.
  • Checking against lists of breached and common passwords is mandatory.
  • A password used on its own needs at least 15 characters. Inside an MFA setup, 8 is enough. And the system must accept at least 64.

OWASP follows the same line in its guidance on authentication failures (OWASP A07). If your system still forces users to change their password every 90 days, it is less secure than if it did not.

Buy or Build Authentication

Writing the login from scratch looks simple until you list what it needs: storing hashes properly, rate limiting attempts, password recovery without opening a hole, MFA, passkey, social login, locking suspicious accounts, auditing. That is why the real question is who is going to take care of it for the next few years.

Path Examples Free plan (Nov 2026) Good for
Ready-made provider (SaaS) Clerk, Auth0 Clerk: 50,000 retained users/month; Auth0: 25,000 active/month A new product that needs full login right away
Platform with built-in auth Supabase, Firebase, AWS Cognito Supabase and Firebase: 50,000 active/month; Cognito: 10,000 Teams already using the platform for database and back-end
Open source on your server Keycloak, Zitadel, Authentik No per-user cost Internal SSO, requirement to keep data on your own server
Library in your code Better Auth, Auth.js Free Teams that want full control and accept the maintenance

Prices come from the official pages in November 2026: the entry paid plan is US$ 25 per month at Clerk and Supabase, and starts at US$ 35 at Auth0 (Clerk, Auth0, Supabase, AWS, Firebase). Be careful when comparing: each one counts "active user" differently.

Two things I learned on the server side:

  • Self-hosted has a cost that does not show up on the bill. I ran a Keycloak to provide SSO for a few internal dashboards. It used almost 2 GB of memory to protect half a dozen screens that only I used. I replaced it with a simple password on the proxy and freed up the machine. SSO pays off when there is a team and many systems, not before.
  • Libraries die too. Lucia, a popular authentication library in the JavaScript ecosystem, was discontinued in March 2025 and became study material (Lucia). Whoever depended on it had to migrate.

What AI Changed in Authentication

AI Agents Need to Log in Too

When an AI agentProgram that uses a language model to choose actions, call tools and repeat the loop until a task is done, with little human input. accesses your calendar or your CRM on your behalf, it needs a credential, and one that grants only the access it needs. MCPOpen protocol that standardizes how AI apps connect to external tools and data: a server exposes actions and the agent discovers and calls them., the protocol that became the standard for connecting agents to systems, did not invent anything new: its authorization specification uses OAuth 2.1 with mandatory PKCE, and forbids the server from passing along the token it received (MCP). It is the same OAuth from this article, now with an agent in the role of the app. I described how I connected an agent to my CRM through MCP in build your own CRM with AI, and the protocol documentation is in MCP Docs.

In practice, the detail that breaks integrations most often is the token lifecycle. In my personal assistant, which reads my Google calendar, the app was still in testing mode in the Google console. In that mode, the refresh token expires in seven days. It expired, syncing stopped, and I went eight days without noticing. It was not a security flaw. What was missing was an alert saying the token had stopped refreshing.

Attacks Got Better Too

  • Phishing. Microsoft reported that AI-made phishing campaigns reach a 54% click rate, 4.5 times more than traditional ones (Microsoft). SMS codes and TOTP do not hold up against a well-made fake page. Passkey does.
  • Fake voices and faces. In 2025 the FBI warned about AI-generated voice messages impersonating officials, with voices that "can sound nearly identical" to the real ones (FBI IC3). Verifying identity by voice over the phone is no longer reliable.
  • A shift in the landscape. In the 2026 Verizon data breach report, for the first time software vulnerabilities (31% of cases) overtook stolen credentials as the main way in (Verizon DBIR). Passwords lost first place, but they are still present in a good share of breaches.

The conclusion is the same from any angle: the phishing-resistant factor is the one worth the investment. Today, that means passkey or a physical key.

How to Choose Authentication for Your System

  1. Who uses it? End customers call for frictionless login (passkey, magic link, social). Company employees call for SSO.
  2. What is at stake? A system with money, health or personal data calls for phishing-resistant MFA from the start.
  3. Who calls the API? If there is integration between systems or AI agents, plan OAuth with narrow permissions right away.
  4. Who will maintain it? Without someone dedicated, a ready-made provider. With a team and a requirement to keep data on your own server, open source.
  5. How much will it grow? Run the per-user pricing math with the number of users you will have two years from now, not today.

For most of the systems I deliver, the combination that works is: email with a long password and breach checking, passkey as an option, MFA for admins, session in an httpOnly cookie and OAuth only where there is integration. If the project is a custom web application, login is in scope from the first conversation, not at the end. And if you want to test your own login, you can start with the back-end testing guide, which has a whole section on security.

Frequently Asked Questions

What is the difference between authentication and authorization?

Authentication confirms who you are. Authorization decides what you can do. The system authenticates first, then authorizes each action.

What are the types of authentication?

The most common are password, code by email or SMS, magic link, authenticator app (TOTP), push notification, social login, corporate SSO, passkey and physical key. For systems that talk to each other, API key, OAuth client credentials and mTLS.

What is the difference between MFA and 2FA?

MFA is using two or more factors from different categories. 2FA is the case with exactly two. Every 2FA is MFA.

Does passkey replace the password?

It can. Many services already allow passkey-only accounts, but most still keep the password as a fallback during the transition.

Is OAuth authentication?

No. OAuth gives an app delegated access. What tells you who the user is is OpenID Connect, built on top of OAuth.

JWT or cookie session?

For a single web application, a session in an httpOnly cookie is simpler and easier to revoke. JWT helps when several services validate the same user. Many systems combine both.

Is SMS as a second factor still safe?

It is better than nothing, but it is the weakest factor: it suffers from SIM swapping and phishing. Prefer an authenticator app or, better yet, passkey.

Is it better to use a provider or build it yourself?

For most products, a provider. Building it yourself pays off when there is an experienced team, a requirement to keep data on your own server, or a per-user cost that makes the provider unviable.

References

Source: https://ramongomessilva.com.br/blog/types-of-authentication · Accessed on December 02, 2026

Share Share on LinkedIn Share on X
Cite this article

Ready-made reference, with today as the access date.

ABNT

Brazilian standard (NBR 6023). Use it in theses and academic papers submitted in Brazil.

GOMES, Ramon. Types of authentication: passwords, MFA, OAuth, passkeys and SSO explained (2026). Ramon Gomes, 12 nov. 2026. Disponível em: https://ramongomessilva.com.br/blog/types-of-authentication. Acesso em: 2 dez. 2026.

APA

American Psychological Association style. Common in scientific papers and journals, especially in the social, behavioral and health sciences.

Gomes, R. (2026, November 12). Types of authentication: passwords, MFA, OAuth, passkeys and SSO explained (2026). Ramon Gomes. https://ramongomessilva.com.br/blog/types-of-authentication

BibTeX

Format for LaTeX users (Overleaf, for example). Paste it into your .bib file or import it into Zotero or Mendeley.

@online{gomes2026typesofauthentication,
  author = {Gomes, Ramon},
  title = {{Types of authentication: passwords, MFA, OAuth, passkeys and SSO explained (2026)}},
  organization = {Ramon Gomes},
  year = {2026},
  month = nov,
  date = {2026-11-12},
  url = {https://ramongomessilva.com.br/blog/types-of-authentication},
  urldate = {2026-12-02}
}
Found a mistake?

Wrong fact, broken link, outdated information: tell me and I will fix it.

10 to 2,000 characters. If you can, point to the right source.

Only so I can reply. It never shows on any page of the site.

Written by

Ramon Gomes

Software Engineer

Full stack software engineer. I like taking a messy problem, listening to the people who live with it and shipping something that holds up day to day. These days I split my time between my own products, applied AI and client work.

Available for projects

Need Something Like This Built?

I build websites, systems, apps and AI automations, from design to deploy. Tell me what you need or see what I offer.

Related Articles