How to Fix Internal Exception: Decoder
Internal Exception: DecoderException means the game received a packet it couldn't read. How to read the cause after it and fix mismatched mods or versions.
Quick Fix
Read the text after DecoderException, then make sure the client and server run the same Minecraft version, the same mods and the same mod versions.
Error Message
Internal Exception: io.netty.handler.codec.DecoderExceptionHow to Fix
Copy the whole message. The client's latest.log has it after Client disconnected with reason, and the server log shows the player's name followed by lost connection.
Check the packet name. clientbound means the client couldn't read what the server sent, and serverbound means the server couldn't read what the client sent.
Install exactly the same mods and versions on the client and the server, and compare both mod lists line by line.
Click Open Report Directory on the disconnect screen, or open the debug folder in your game directory. The newest file whose name starts with disconnect and ends with client.txt holds the full stack trace.
Remove proxy and protocol plugins for a test to see whether the error goes away.
Common Causes
- A mod is missing or has a different version on one side, so the client and server disagree about what a packet contains. The cause often starts with Failed to decode packet and names the packet, such as clientbound/minecraft:custom_payload, which carries mod data.
- A packet has more bytes than the code reading it used, which also points to a mismatch. The cause is then a java.io.IOException that names the packet and says how many bytes were extra.
- Compressed data doesn't match its declared size or the compression threshold. The cause then starts with Badly compressed packet.
- A proxy or plugin between client and server, such as one that translates versions or rewrites packets, sends data the other side doesn't expect.
Diagnostic Steps
- Copy the full message from the disconnect screen or latest.log.
- Check whether the packet is clientbound or serverbound.
- Compare the mod lists on client and server.
- Match or update the mod, then reconnect.
FAQ
What is a DecoderException?
Netty's error for data that couldn't be turned back into a packet. Minecraft shows it as Internal Exception followed by the exception and its cause.
Does Internal Exception mean my game is broken?
No. It is the game's general wrapper for connection errors, and the part after it tells you what actually went wrong.
Can a server plugin cause it?
Yes, when a plugin or proxy sends packets the client doesn't expect. Test without plugins that translate versions or change packets to rule them out.
Related Errors
How to Fix java.net.SocketException
java.net.SocketException: Connection reset
How to Fix Client-Server Mod Mismatch
Mod rejections: X - client has Y, server has Z
How to Fix Packet Too Large / Payload Too Large
Packet too large! / Payload may not be larger than X bytes
How to Fix IndexOutOfBoundsException
java.lang.IndexOutOfBoundsException: Index 0 out of bounds for length 0