Discord error 50006: Cannot send an empty message
Last verified against Discord Developer Docs - Opcodes and status codes
Cannot send an empty messageWhat error 50006 means
The message you tried to send or edit has nothing in it: no content, no embeds, no files/attachments, no sticker_ids, no poll, and no components (or components that do not count as content under the Components v2 flag). Discord requires at least one of these.
It almost always means a bug upstream of the send: a template that rendered to an empty string, a conditional that skipped building the embed, an undefined variable interpolated as nothing, or a response from another service that came back empty and was forwarded as-is. In edits it appears when you PATCH with content: "" on a message that has no embeds, which leaves nothing behind.
An embed object with all fields empty also counts as empty. And whitespace-only content is trimmed and treated as empty.
Discord counts a message as non-empty when at least one of these is present and non-blank: content, embeds, files/attachments, sticker_ids, poll, or components sent under the Components v2 flag. Everything else, including allowed_mentions, flags, reply references and tts, is metadata that cannot carry a message on its own. The upstream bugs cluster in three places: template rendering (a variable that resolved to undefined, a translation key that is missing in one locale), conditional assembly (the code path that builds the embed was skipped but the send still ran), and pass-through (an upstream API or AI model returned an empty string and nothing checked). Edits have their own version: PATCHing content: "" on a message whose only other payload was that content leaves nothing, so the edit is rejected rather than producing a blank message.
What it looks like
{
"message": "Cannot send an empty message",
"code": 50006
}Why it happens
- content is an empty string, whitespace, null, or undefined and no embeds/files are present
- Embed built from missing data so every field is blank
- Edit that clears content on a message with no other payload
- Components-only message sent without the IS_COMPONENTS_V2 flag (components alone are not content under v1)
- Truncation logic that cut content to zero length
How to fix Discord error 50006
- 1Log the exact payload before sending and assert that at least one of content, embeds, files, sticker_ids, poll is non-empty
- 2Guard the send with a fallback string for the empty case, or skip the send entirely
- 3For edits that should remove text but keep embeds, send content: null only when embeds remain, or delete the message
- 4For components-only layouts, set flags: 1 << 15 (IS_COMPONENTS_V2) and use v2 components
- 5Check upstream data sources for empty responses and handle them explicitly
How to stop it recurring
Route all outgoing messages through one builder that validates non-emptiness and field lengths before the HTTP call, with a unit test for the empty case. Many silent "bot did nothing" reports turn out to be 50006 swallowed by a catch block; log it.
The content, embed and attachment minimums live next to their maximums on the Discord limits page; a bot that seems to "do nothing" on certain inputs is often swallowing exactly this error, a pattern covered in Discord bot not responding.
Official reference: Discord Developer Docs - Opcodes and status codes. See all Discord error codes or the Discord limits and quotas.
Related codes
Error 50006 - quick answers
What does Discord error 50006 mean?
The message you tried to send or edit has nothing in it: no content , no embeds , no files / attachments , no sticker_ids , no poll , and no components (or components that do not count as content under the Components v2 flag). Discord requires at least one of these.
How do I fix Discord error 50006?
1. Log the exact payload before sending and assert that at least one of content, embeds, files, sticker_ids, poll is non-empty 2. Guard the send with a fallback string for the empty case, or skip the send entirely 3. For edits that should remove text but keep embeds, send content: null only when embeds remain, or delete the message 4. For components-only layouts, set flags: 1 << 15 (IS_COMPONENTS_V2) and use v2 components 5. Check upstream data sources for empty responses…
Should I retry after error 50006?
No. Retrying the same request produces the same error; the condition has to be fixed first. Treat it as a permanent failure for that message and surface it, rather than looping.
Stop debugging Discord by hand
Connect the channel through Conferbot: tokens, webhooks and retries are handled, failures show as readable status.