WhatsApp error 131051: Unsupported message type
Last verified against Meta for Developers - Cloud API error codes
Unsupported message type.What error 131051 means
Code 131051 means the type you sent, or the shape of the object that goes with it, is not something the Cloud API will accept on this endpoint. The supported top-level types are a fixed list (text, image, audio, video, document, sticker, location, contacts, interactive, template, reaction, and a few others) and the platform rejects anything else outright. It also appears when a media message references a file whose MIME type is outside the supported set, because the platform cannot classify it as any deliverable type.
Most hits come from three places: a typo or casing mismatch in the type string, a value borrowed from another messaging platform (for example, file or photo), and media uploaded with a correct-sounding extension but an unsupported actual format such as a GIF, HEIC, or an MKV container.
The recipient, window, and token are irrelevant here; the request itself is not a message WhatsApp can send.
The rejection is synchronous - the type check runs before the message is accepted, so no message ID is issued and no statuses webhook follows. The full matrix of supported formats and size ceilings per media type is tabulated in the WhatsApp media limits table. Distinguish it from 131053, where the type is fine but the platform could not fetch or process the file, and from code 100, which flags unknown keys rather than unknown types. One gotcha for teams on multi-channel abstractions: if your BSP or messaging layer normalizes payloads across channels, a message type that is legal on another channel (a GIF, a generic file attachment) can reach WhatsApp as unsupported, so check the WhatsApp-specific mapping in your provider's documentation rather than the generic one.
What it looks like
{
"error": {
"message": "(#131051) Unsupported message type",
"type": "OAuthException",
"code": 131051,
"error_data": {
"messaging_product": "whatsapp",
"details": "Message type is not currently supported"
},
"fbtrace_id": "AzXcVbNm12QwEr"
}
}Why it happens
- type set to a value that is not in the supported list, or with different capitalization.
- A media file whose real MIME type is unsupported (GIF sent as image, HEIC, WebM or MKV video, WAV audio).
- MIME type inferred from the filename rather than the file content, masking an unsupported format.
- Sending an interactive sub-type that is not available for your account or API version.
- Sticker files that are not WebP.
How to fix WhatsApp error 131051
- 1Check the type string against the send-messages reference and correct spelling and case.
- 2Detect the file's real MIME type from its bytes (for example with file -I) and compare against the supported media types list.
- 3Transcode unsupported media: convert GIF and HEIC to JPEG or PNG, WebM or MKV to MP4 with H.264 and AAC, WAV to MP3 or AAC.
- 4Re-upload the converted file to /{phone-number-id}/media and send with the returned media ID.
- 5Retry the message with the corrected type and asset.
How to stop it recurring
Whitelist message types and MIME types in your sending code and reject anything else before it reaches the API, with a conversion step for common unsupported formats. Sniff MIME types from content, never from extensions, and include the supported media matrix in the tests you run against each message type.
Official reference: Meta for Developers - Cloud API error codes. See all WhatsApp error codes or the WhatsApp limits and quotas.
Related codes
- 131053: Media upload errorUnable to upload the media used in the message.
- 131052: Media download errorUnable to download the media sent by the user.
- 100: Invalid parameterThe request included one or more unsupported or misspelled parameters.
- 131009: Parameter value is not validOne or more parameter values are invalid.
Error 131051 - quick answers
What does WhatsApp error 131051 mean?
Code 131051 means the type you sent, or the shape of the object that goes with it, is not something the Cloud API will accept on this endpoint. The supported top-level types are a fixed list (text, image, audio, video, document, sticker, location, contacts, interactive, template, reaction, and a few others) and the platform rejects anything else outright.
How do I fix WhatsApp error 131051?
1. Check the type string against the send-messages reference and correct spelling and case. 2. Detect the file's real MIME type from its bytes (for example with file -I) and compare against the supported media types list. 3. Transcode unsupported media: convert GIF and HEIC to JPEG or PNG, WebM or MKV to MP4 with H.264 and AAC, WAV to MP3 or AAC. 4. Re-upload the converted file to /{phone-number-id}/media and send with the returned media ID. 5. Retry the message with the…
Stop debugging WhatsApp by hand
Connect the channel through Conferbot: tokens, webhooks and retries are handled, failures show as readable status.