Discord error 160009: Cannot reference a message without Read Message History
Last verified against Discord Developer Docs - Opcodes and status codes
Cannot reference a message without permission to read message historyWhat error 160009 means
Your message includes a message_reference pointing at another message, and the bot lacks Read Message History where that message lives. Referencing earlier messages requires being able to read them.
This is the general form of the rule. 160002 covers the reply case specifically; 160009 can also arise from other references, for example forwarding a message. The fix is the same: grant Read Message History in the source channel, or stop referencing the message.
A channel overwrite that denies Read Message History to @everyone or to the bot's role is the usual cause, often in announcement or log channels where admins hide history.
View Channel alone is not enough. A bot can see a channel and receive new messages there while still being denied the history permission that references require.
What it looks like
{
"message": "Cannot reference a message without permission to read message history",
"code": 160009
}Why it happens
- Bot lacks Read Message History in the channel of the referenced message
- Channel overwrite denies Read Message History to the bot's role
- Forwarding a message from a channel the bot can see but not read history in
- Reference points to a message in a different channel than the one you are sending to
How to fix Discord error 160009
- 1Check the bot's effective permissions in the source channel for Read Message History
- 2Grant it via the bot's role or a bot-specific channel overwrite
- 3If you cannot, send the message without message_reference
- 4Retry and confirm the reference renders
- 5Confirm the channel_id and message_id in message_reference point to the message you intend
How to stop it recurring
Include Read Message History in the bot's invite permissions if it replies to or references messages, and fall back to a plain message when a reference fails. The Discord permissions calculator helps build the invite bitfield. Check the permission at configuration time too.
Official reference: Discord Developer Docs - Opcodes and status codes. See all Discord error codes or the Discord limits and quotas.
Related codes
- 160002: Cannot reply without permission to read message historyCannot reply without permission to read message history
- 160014: Cannot forward a message you cannot readYou cannot forward a message whose content you cannot read
- 50013: Missing permissionsYou lack permissions to perform that action
- 50001: Missing accessMissing access
Error 160009 - quick answers
What does Discord error 160009 mean?
Your message includes a message_reference pointing at another message, and the bot lacks Read Message History where that message lives. Referencing earlier messages requires being able to read them. This is the general form of the rule. 160002 covers the reply case specifically; 160009 can also arise from other references, for example forwarding a message.
How do I fix Discord error 160009?
1. Check the bot's effective permissions in the source channel for Read Message History 2. Grant it via the bot's role or a bot-specific channel overwrite 3. If you cannot, send the message without message_reference 4. Retry and confirm the reference renders 5. Confirm the channel_id and message_id in message_reference point to the message you intend
Stop debugging Discord by hand
Connect the channel through Conferbot: tokens, webhooks and retries are handled, failures show as readable status.