Driver FixRecommendedSound, Wi-Fi or graphics acting up? Check drivers firstFind missing or outdated drivers fast.Check DriversOctober DealsAmazon USOctober deal check: compare before you payAmazon US: current deals, useful picks and tech finds.Check DealsSlow PC?RecommendedPC slow today? Run a repair scan before it gets worseResolve common Windows issues and optimize system performance.Scan Now×
Skip to content
World desk3 min

The MCP Session Refresh Gotcha: Why “Token Expired” and “Session Expired” Are Different Errors

MCP “Token Expired” and “Session Expired” messages can describe different failures. Check HTTP status, token renewal, transport, and version-specific session state before choosing a fix.
Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

“Token Expired” and “Session Expired” are not interchangeable diagnoses. An expired OAuth access token, an unusable refresh token, and an expired application or protocol session belong to separate state machines. The message text alone does not identify which one failed: these phrases are common error labels, not established standardized MCP error strings.

What “token” and “session” mean

Access token: authorization for a request

For an HTTP-based MCP server, the client sends the bearer access token in the Authorization header on each request, including requests associated with the same logical application session. Under the MCP Authorization specification dated 2025-06-18, invalid or expired tokens must receive HTTP 401. See the 2025-06-18 authorization specification.

As an Amazon Associate I earn from qualifying purchases.

Do not send access tokens in query strings. For STDIO transports, the authorization specification advises implementations to obtain credentials from the environment rather than use the HTTP authorization mechanism.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Refresh token: a separate credential

A refresh token is presented to the authorization server to request another access token. It is not the access token, and MCP clients must not assume one will be issued: the authorization server retains discretion. The 2026-07-28 MCP authorization specification states that clients “MUST NOT assume refresh tokens will be issued; the AS retains discretion.”

#1 Best Overall
Yubico - Security Key C NFC - Basic Compatibility - Multi-Factor authentication (MFA) Security Key and passkey, Connect via USB-C or NFC, FIDO Certified
  • POWERFUL SECURITY KEY: The Security Key C NFC is the essential physical passkey for protecting your digital life from phishing attacks. It ensures only you can access your accounts.
  • WORKS WITH 1000+ ACCOUNTS: Compatible with Google, Microsoft, and Apple. A single Security Key C NFC secures 100 of your favorite accounts, including email, password managers, and more.
  • FAST & CONVENIENT LOGIN: Plug in your Security Key C NFC via USB-C and tap it, or tap it against your phone (NFC) to authenticate. No batteries, no internet connection, and no extra fees required.
  • TRUSTED PASSKEY TECHNOLOGY: Uses the latest passkey standards (FIDO2/WebAuthn & FIDO U2F) but does not support One-Time Passwords. For complex needs, check out the YubiKey 5 Series.
  • BUILT TO LAST: Made from tough, waterproof, and crush-resistant materials. Manufactured in Sweden and programmed in the USA with the highest security standards.

Even when a client has a refresh token, renewal is not guaranteed. The authorization server may reject a token that has expired, been revoked, or become unusable after rotation. RFC 9700 discusses refresh-token expiration and rotation as OAuth security concerns and says refresh tokens should expire after a period of inactivity: RFC 9700. Clients should protect refresh tokens both in transit and in storage, and correctly store any replacement token returned during rotation.

Session: implementation- and version-dependent state

“Session” may refer to state maintained by the surrounding application, an MCP client or server, or a version-specific protocol lifecycle. It does not inherently mean that an OAuth credential expired. The MCP project’s 2026-07-28 release announcement says that release retires the former initialize/initialized exchange and the Mcp-Session-Id header. Do not assume those older session mechanics apply to implementations based on that release.

Rank #2
Yubico - YubiKey 5C NFC - Multi-Factor authentication (MFA) Security Key and passkey, Connect via USB-C or NFC, FIDO Certified - Protect Your Online Accounts
  • POWERFUL SECURITY KEY: The YubiKey 5C NFC is the most versatile physical passkey, protecting your digital life from phishing attacks. It ensures only you can access your accounts
  • WORKS WITH 1000+ ACCOUNTS: Compatible with popular accounts like Google, Microsoft, and Apple. A single YubiKey 5C NFC secures 100+ of your favorite accounts, including email, password managers, and more
  • FAST & CONVENIENT LOGIN: Plug in your YubiKey 5C NFC via USB and tap it, or tap it against your phone (NFC), to authenticate. No batteries, no internet connection, and no extra fees required
  • MOST SECURE PASSKEY: Supports FIDO2/WebAuthn, FIDO U2F, Yubico OTP, OATH-TOTP/HOTP, Smart card (PIV), and OpenPGP. That means it’s versatile, working almost anywhere you need it
  • PRIMARY & SPARE KEYS: Just like having a spare house key, we recommend buying two YubiKeys - one for daily use and one as a spare. That way you’ll never get locked out of your accounts

Compare the evidence before choosing a fix

Diagnostic axis Token problem Session problem
State owner Authorization server and client credential store MCP client/server or surrounding application, depending on implementation
Evidence to inspect Authorization header, HTTP status, and token or refresh response Client/server lifecycle logs, connection state, and version-specific session mechanism
Typical action Refresh if a valid refresh token is available; otherwise authorize again Use that implementation’s documented recovery or reconnect behavior
Version sensitivity Check the applicable transport and authorization specification High; session mechanics changed in the 2026-07-28 release announcement

This is a diagnostic framework, not a claim that every implementation exposes the same logs or recovery controls.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Diagnose the failure in order

  1. Record the transport and versions. Determine whether the connection uses HTTP, STDIO, or another transport, and note the MCP specification version used by both client and server. The MCP authorization mechanism is intended for HTTP transports; STDIO implementations are advised to obtain credentials from the environment.
  2. Inspect the HTTP response, if applicable. Record whether the server returned 401 or 403 and capture the relevant WWW-Authenticate challenge. Never log bearer credentials. In the 2025-06-18 authorization specification, 401 indicates missing or invalid authorization, including an invalid or expired token; 403 indicates invalid scopes or insufficient permissions. A 403 is a different diagnostic branch from an expired-token 401. Verify the target specification version before applying this guidance.
  3. Verify the access-token request path. Confirm that the client sends the intended bearer access token in the Authorization header on every HTTP request, not just when it first establishes a logical application session. Do not place it in a URL.
  4. Check refresh independently. If the client has a refresh token, inspect the authorization server’s response and determine whether a rotated replacement was saved correctly. Do not infer that a refresh token exists merely because the client supports OAuth.
  5. Inspect session state independently. Check the application’s own session expiration, connection state, and the lifecycle behavior for the MCP versions in use. In particular, do not assume that an implementation based on the 2026-07-28 release has an Mcp-Session-Id header.
  6. Match recovery to the evidence. A valid refresh token may yield a new access token. If the refresh token is expired, revoked, or unavailable, a fresh authorization flow may be needed. For a server-side or application-session failure, use that client and server’s documented reconnect or recovery behavior; there is no universal reinitialization fix.
Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

Read the error label as a clue, not a diagnosis

A 401 under the cited authorization specification points toward missing or invalid authorization; a 403 points toward scope or permission problems. Neither status alone describes every application’s session state, and a user-facing “Session Expired” label does not prove the access token is expired. Likewise, a refresh failure does not establish that an MCP protocol session expired. Use the response, credential flow, implementation logs, and version-specific documentation to identify the failed state machine.

Best Value
FIDO2 U2F Security Key Passkey Two-Factor Authentication (2FA) USB Key PIN+Touch (Non-Biometric) USB-A Type TrustKey T110
  • Security Key : Protect your online accounts against unauthorized access by using FIDO2 and U2F authentication with T110. It's the world's most protective security key that works with windows, Mac OS, Linux as well as Chrome, Firefox, Edge and many other major browsers.
  • Certified with the new FIDO2 standard, T110 provides the benefit of fast login and strong protection against phishing, account takeover as well as many other online attactks.
  • Works with : Bank of America, Github, Google, Microsoft, DUO, Twitter, Facebook, Dropbox, Apple, ebay, BINANCE, mor and more.
  • Fits USB-A port : Insert the T110 security key into the USB-A port of each service and log in conveniently with one touch
  • For the driver download and user guide, please visit TrustKey Solutions Home support page.
Rank #4
Yubico - Security Key NFC - Basic Compatibility - Multi-Factor Authentication (MFA) Key, Connect via USB-A or NFC, FIDO Certified
  • POWERFUL SECURITY KEY: The Security Key NFC is the essential physical passkey for protecting your digital life from phishing attacks. It ensures only you can access your accounts.
  • WORKS WITH 1000+ ACCOUNTS: Compatible with Google, Microsoft, and Apple. A single Security Key NFC secures 100 of your favorite accounts, including email, password managers, and more.
  • FAST & CONVENIENT LOGIN: Plug in your Security Key NFC via USB-A and tap it, or tap it against your phone (NFC) to authenticate. No batteries, no internet connection, and no extra fees required.
  • TRUSTED PASSKEY TECHNOLOGY: Uses the latest passkey standards (FIDO2/WebAuthn & FIDO U2F) but does not support One-Time Passwords. For complex needs, check out the YubiKey 5 Series.
  • BUILT TO LAST: Made from tough, waterproof, and crush-resistant materials. Manufactured in Sweden and programmed in the USA with the highest security standards.
Rank #3
Yubico - YubiKey 5 NFC - Multi-Factor authentication (MFA) Security Key and passkey, Connect via USB-A or NFC, FIDO Certified - Protect Your Online Accounts
  • POWERFUL SECURITY KEY: The YubiKey 5 NFC is the most versatile physical passkey, protecting your digital life from phishing attacks. It ensures only you can access your accounts
  • WORKS WITH 1000+ ACCOUNTS: Compatible with popular accounts like Google, Microsoft, and Apple. A single YubiKey 5 NFC secures 100+ of your favorite accounts, including email, password managers, and more
  • FAST & CONVENIENT LOGIN: Plug in your YubiKey 5 NFC via USB and tap it, or tap it against your phone (NFC), to authenticate. No batteries, no internet connection, and no extra fees required
  • MOST SECURE PASSKEY: Supports FIDO2/WebAuthn, FIDO U2F, Yubico OTP, OATH-TOTP/HOTP, Smart card (PIV), and OpenPGP. That means it’s versatile, working almost anywhere you need it
  • PRIMARY & SPARE KEYS: Just like having a spare house key, we recommend buying two YubiKeys - one for daily use and one as a spare. That way you’ll never get locked out of your accounts

Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.

Leave a Reply

Your email address will not be published. Required fields are marked *

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

More from the Wire

  1. World desk4 min
    How to Spot an AI Voice Scam Before Sending MoneyDon’t rely on how a caller sounds. Pause, call back through a known number, and verify the emergency with another trusted person before sending money.
  2. Mountain View desk4 min
    Google’s SynthID Detector: How to Check AI-Generated Images, Video and AudioGoogle’s SynthID Detector looks for an embedded watermark in supported images, video and audio. Here is what its results do—and do not—show.
  3. Redmond desk20 min
    How to create a link to File or Folder in Windows 11Windows 11 gives you several ways to point to a file or folder without moving or duplicating it. You can create a desktop shortcut,…
Recommended PC Tool
Recommended PC Tool
Crashes, No Sound, or Screen Glitches?Free driver scan
Windows Errors? Fix Them Before They SpreadFree repair scan

Two free Windows tools

One Free Minute Could Fix That PC

Before you go - each of these free tools takes about a minute and tackles what quietly slows a Windows PC down.

Special offer. View Outbyte info, uninstall instructions, EULA, and Privacy Policy.