All guidesVercel and env vars
On this page

Next.js runtime error

Failed to find Server Action "...". This request might be from an older or newer deployment.

By Ohad Krispin, founder of VibeRaven · LinkedIn

"Failed to find Server Action ... This request might be from an older or newer deployment" means a browser sent a Server Action ID that the running build does not have. Next.js gives each action an ID per build, and its docs say the IDs can change between builds; a tab opened before your deploy still holds the old ID, so its next form submit gets HTTP 409, "Server Action unavailable.", and nothing runs. In our run even a clean rebuild of unchanged code changed the ID. On Vercel, Skew Protection keeps the old deployment answering for its own tabs. Self-hosted on several servers, build once and set the same NEXT_SERVER_ACTIONS_ENCRYPTION_KEY at build time for every instance. Reproduced with Next.js 16.4.3 and checked against the Next.js source on 2026-10-27.

Next.js 16.4.3: a tab opened on one build submits a form after a rebuild, the server logs Failed to find Server Action with the old ID and answers 409 Server Action unavailable.
Next.js 16.4.3: a tab opened on one build submits a form after a rebuild, the server logs Failed to find Server Action with the old ID and answers 409 Server Action unavailable.

What the user and the logs see

The server log prints the error with the old ID and a link to the Next.js docs. The browser gets a 409, and in our run the page threw UnrecognizedActionError and did not reload, so the form looks like it did nothing. A refresh loads the new build and the form works again.

Error: Failed to find Server Action "404be4ca319f91ec03c4d55707967f2a000bac4ceb". This request might be from an older or newer deployment.
Read more: https://nextjs.org/docs/messages/failed-to-find-server-action

On Vercel: Skew Protection

Skew Protection serves requests from an old page to the deployment that page came from, so its actions still exist. Vercel's docs say it is available on Pro and Enterprise plans, is on by default for projects created after November 19th 2024, and keeps old deployments reachable for one day by default, configurable up to the project's deployment retention. Check it in the project's Settings, under Advanced. A deployment that was deleted is not reachable through it.

Self-hosted on several servers or containers

Next.js's page for this error says every instance must run the same build output and encryption key. Build once and ship that output everywhere; a build per container gives each one its own IDs. Set NEXT_SERVER_ACTIONS_ENCRYPTION_KEY, a base64 AES key of 16, 24 or 32 bytes, at build time: in our run, two clean builds with the same key produced the same action ID.

openssl rand -base64 32

Requests from scanners

A Next-Action header with an ID in the wrong format logs a different error, The Server Reference ID did not match the expected format, with HTTP 400. Next.js's docs say malformed requests from automated security scanning can cause it, so a few of those in the logs are not your users.

Checklist

How to fix it, then check the fix

  1. 01Check whether the errors start right after a deploy: then they come from tabs opened on the previous build.
  2. 02On Vercel, check that Skew Protection is on for the project, or upgrade the plan if it is not available.
  3. 03Self-hosted, build once, run the same output on every instance, and set NEXT_SERVER_ACTIONS_ENCRYPTION_KEY at build time.
  4. 04Show the user a retry or reload message when an action call fails, instead of a form that does nothing.
  5. 05Open the app, deploy a change, then submit a form from the old tab: it succeeds, or the page reloads.

Related

Sources

Official docs behind this checklist

FAQ

FAQ for builders before launch

Is my Server Action broken?

No. The action runs in a fresh page. The request came from a page built against another deployment.

Why does it happen when the action did not change?

The IDs are not fixed per action: in our run a clean build of the same code produced new ones. Every deploy can change them.