Instagram Messaging API · error code

Instagram error -2: Media has expired - upload again (2207020)

RetryableHTTP 400Content publishing (posts, reels, stories)

Last verified against Meta for Developers - Messenger Platform error codes

What Instagram returns
The media you are trying to access has expired. Please try to upload again.

What error -2 means

Subcode 2207020, with top-level code -2, tells you the media referenced by your request has expired. Meta's recommended solution is to generate a new container ID and use it to try again, which matches the message's own advice to upload again.

Containers are not permanent. The IG User media reference states that containers expire after 24 hours, and the container status endpoint reports EXPIRED for one that was not published within that window. An app that prepares media early and publishes much later, or that retries a failed publish the next day with the same ID, runs straight into this.

It overlaps in spirit with 24/2207008, which also covers expired containers, but the remedy is identical and simple: the old ID is dead, so build a new container with the same media and caption. There is nothing to repair on the account, the token or the media file.

What it looks like

{
  "error": {
    "type": "OAuthException",
    "code": -2,
    "error_subcode": 2207020,
    "error_user_msg": "The media you are trying to access has expired. Please try to upload again.",
    "fbtrace_id": "VxA8nTy6DqGb2Hm"
  }
}

Why it happens

  • The container was created more than 24 hours before the publish attempt.
  • A retry job replayed a container ID from a previous day.
  • A scheduled post reused a container prepared when the post was drafted.
  • A long-running video process left the container unpublished past its lifetime.

How to fix Instagram error -2

  1. 1Confirm with GET /<IG_CONTAINER_ID>?fields=status_code that the container reports EXPIRED.
  2. 2Create a new container using the same media URL, caption and options.
  3. 3Publish the new container once its status is FINISHED.
  4. 4Make sure the media URL is still live before rebuilding, since it must be fetchable again.

How to stop it recurring

Create containers just in time, close to the publish slot, and store the inputs rather than the container ID in your scheduler. Record when each container was made and rebuild automatically if it is older than 24 hours. Keep the hosted media alive until the post is confirmed PUBLISHED so a rebuild is always possible.

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

Related codes

Error -2 - quick answers

What does Instagram error -2 mean?

Subcode 2207020, with top-level code -2 , tells you the media referenced by your request has expired. Meta's recommended solution is to generate a new container ID and use it to try again, which matches the message's own advice to upload again. Containers are not permanent.

How do I fix Instagram error -2?

1. Confirm with GET /<IG_CONTAINER_ID>?fields=status_code that the container reports EXPIRED . 2. Create a new container using the same media URL, caption and options. 3. Publish the new container once its status is FINISHED . 4. Make sure the media URL is still live before rebuilding, since it must be fetchable again.

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 Instagram by hand

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