Firebase App Check: requests rejected (403 / app-check-token-is-invalid / attestation failed)

With App Check enforced, calls without a valid attestation token are blocked.

Exact message you may see App Check token is invalidfirebase app check 403Firebase App Check token is invalid.
Seen on: Firebase JavaScript

Meaning

Register the app with a provider (reCAPTCHA v3/Enterprise, Play Integrity, DeviceCheck/App Attest), initialise App Check before other Firebase calls, use a debug token for emulators/CI (self.FIREBASE_APPCHECK_DEBUG_TOKEN = true and register the token), and check "Unenforced" vs "Enforced" modes.

Common causes

  • App Check enforced but SDK not initialised
  • Wrong provider/site key
  • Debug token not registered
  • Emulator/simulator without attestation
  • Domain not allowed for reCAPTCHA

⚡ Quick fix

  1. Initialise App Check before using services
  2. Register a debug token for dev/CI
  3. Verify provider keys and allowed domains

Detailed fix by platform

JavaScript

  1. initializeAppCheck(app, { provider: new ReCaptchaV3Provider("SITE_KEY"), isTokenAutoRefreshEnabled: true });

How to diagnose

  1. Enforcement — On?
  2. Provider — Configured?
  3. Debug token — Registered?

🔧 Still not fixed?

Many errors look alike. If the steps above didn’t solve it, one of these is probably what you’re facing:

Where this error sits

Origin: Platform & cloud. Errors that are often confused with or caused by this one (click to open):

15281 — SQL Server Msg 15281: SQL Server blocked access to procedure 'sys.xp_cmdshell' (component 'xp_cmdshell' turned off) (SQL)15281AADSTS50053 — AADSTS50053: Your account is locked (Smart Lockout) / sign-in blocked due to suspicious activity (Azure)AADSTS50053APNs — FCM: THIRD_PARTY_AUTH_ERROR — APNs credentials missing or invalid (iOS push not delivered) (Google Cloud / Firebase)APNsauth/account-exists-with-different-credential — Firebase Auth: account exists with a different credential (same email, other provider) (Google Cloud / Firebase)auth/account-exists-w…auth/email-already-in-use — Firebase Auth: auth/email-already-in-use — The email address is already in use by another account (Google Cloud / Firebase)auth/email-already-in…auth/invalid-api-key — Firebase: auth/invalid-api-key — Your API key is invalid, please check you have copied it correctly (Google Cloud / Firebase)auth/invalid-api-keyauth/invalid-credential — Firebase Auth: auth/invalid-credential (auth/wrong-password, auth/user-not-found, auth/invalid-login-credentials) (Authentication)auth/invalid-credenti…auth/network-request-failed — Firebase Auth: auth/network-request-failed — A network AuthError (such as timeout, interrupted connection or unreachable host) has occurred (Authentication)auth/network-request-…App Check

Explore the map of this error Full error map →

🧠 Still stuck? Analyze your error

Paste the full message, response headers or stack trace — we'll detect the platform and point to the most likely cause.

💬 What worked for others

No tips yet — did something else fix this for you?

Share what worked for you

Tips are checked by an editor before they appear. Links are removed.