Messenger Platform · error code

Messenger error 2: Unexpected error - retry later

RetryableHTTP 500Generic & request errors

Last verified against Meta for Developers - Messenger Platform error codes

What Messenger returns
An unexpected error has occurred. Please retry your request later.

What error 2 means

Code 2 is the Graph API's service-trouble signal: "An unexpected error has occurred. Please retry your request later." The error-handling guide files it as "API Service: temporary issue due to downtime, wait and retry the operation." Meta's Messenger error-codes table gives the same advice, check the Meta Developer Platform status page when it appears, and then adds a caveat unique to this platform: "You might also receive this error if a customer has blocked your business from messaging him or her."

That caveat changes how a Messenger bot should treat code 2. On most Graph surfaces it is purely transient and retry-safe; on Messenger sends, a persistent code 2 for one specific recipient may actually be a blocked relationship wearing the wrong error, behavior normally announced by 551. The retry policy should therefore be scoped: retry a handful of times with backoff, but if one PSID keeps failing while others succeed, reclassify that contact as possibly-unreachable rather than retrying forever.

The distributional test is the quickest diagnosis. Errors spread across many recipients and endpoints, with Meta Status showing an incident: transient, pause and drain later. Errors concentrated on one recipient while the rest of the queue flows: recipient-side, suppress the contact. Its transient siblings 1 and 1200 share the retry machinery; only code 2 carries the documented blocked-customer ambiguity.

What it looks like

{
  "error": {
    "message": "An unexpected error has occurred. Please retry your request later.",
    "type": "OAuthException",
    "code": 2,
    "fbtrace_id": "Fz54k3GZrio"
  }
}

Why it happens

  • Temporary downtime or degradation in Meta's API service.
  • Platform incidents visible on the Meta Status dashboard.
  • A customer having blocked the business, surfacing as code 2 instead of 551.
  • Load spikes causing sporadic backend failures.
  • Occasionally, requests routed to degraded infrastructure during maintenance.

How to fix Messenger error 2

  1. 1Retry with exponential backoff and jitter, using idempotency keys to prevent duplicates.
  2. 2Check Meta Status during bursts; pause the queue during declared incidents rather than burning retries.
  3. 3Track failures per recipient: persistent code 2 on one PSID while others succeed suggests a block, handle like 551.
  4. 4Cap total retries and park failed messages for later inspection instead of dropping them.
  5. 5Record fbtrace_id values for any sustained pattern and report via Developer Support.

How to stop it recurring

Same discipline as all transients: durable queue, backoff, idempotency, and status-page awareness in the pager runbook. Add the per-recipient failure counter, it is the only way to catch the documented blocked-customer case hiding inside a transient code. The classification logic for 1, 2 and 1200 versus the permanent family is drawn out in the Messenger troubleshooting guide.

Official reference: Meta for Developers - Messenger Platform error codes. See all Messenger error codes or the Messenger limits and quotas.

Related codes

Error 2 - quick answers

What does Messenger error 2 mean?

Code 2 is the Graph API's service-trouble signal: "An unexpected error has occurred.

How do I fix Messenger error 2?

1. Retry with exponential backoff and jitter, using idempotency keys to prevent duplicates. 2. Check Meta Status during bursts; pause the queue during declared incidents rather than burning retries. 3. Track failures per recipient: persistent code 2 on one PSID while others succeed suggests a block, handle like 551. 4. Cap total retries and park failed messages for later inspection instead of dropping them. 5. Record fbtrace_id values for any sustained pattern and report…

Can I retry after error 2?

Yes - this is a retryable condition. Back off (start around one second and double on each attempt, with jitter) and watch for a retry-after hint from the platform before resending.

Stop debugging Messenger by hand

Connect the channel through Conferbot: tokens, webhooks and retries are handled, failures show as readable status.