TXT · Text & Data tools

RLP Decoder

Input encoding
Indent
Or load a file
Encoded bytes
Decoded
RLPformat0 Binput0lines out0chars out
Open the full binary format decoder with every format and the encoder

Shareable link

Settings are written to the URL as you change them. Nothing differs from the defaults yet.

Two types, nothing else

RLP encodes byte strings and lists of byte strings. There are no numbers, no maps, no booleans, and no strings in the text sense. Everything an Ethereum client stores in it, a nonce, an address, a gas limit, is a minimal big-endian byte string, and the meaning comes from the position in the list.

A single byte below 0x80 encodes itself. 0x83646f67 is a 3-byte string, dog. 0xc88363617483646f67 is a list holding cat and dog.

Reading a transaction

A legacy transaction is a list of nine items: nonce, gas price, gas limit, to, value, data, v, r, s. An EIP-1559 transaction is a list of twelve, prefixed by the type byte 0x02 which sits outside the RLP payload and has to be removed first.

Empty items are common and correct. A contract creation has an empty to, and a plain transfer has empty data. Both show as <empty> rather than as zero, because RLP distinguishes an empty string from a byte holding zero.

Leading zeros

RLP requires the minimal encoding of a number, so a value of 1 is 0x01 and never 0x0001. A payload carrying leading zeros in a quantity field was produced by a broken encoder and will hash differently from the canonical form, which is enough to invalidate a signature.

Frequently Asked Questions

RLP has exactly two types, byte string and list, and no way to say what a string means. Items of 8 bytes or fewer also show their numeric value, since that is what short fields usually are.

Typed transactions from EIP-2718 start with a type byte, 0x02 for EIP-1559, before the RLP payload. Remove that first byte and the rest decodes as a list.

No. Field order comes from the transaction type, not from the encoding. The decoder returns the list in order, so match it against the spec for that type.

Pages locked to one format

Full Binary Format Decoder tool

Explore Our Tools

Browse all tools