Data URI Parser & Decoder
Decode a data: URI to see its MIME type, encoding, size and decoded contents, in your browser.
How to use
- Paste a full data: URI into the input box.
- Read the MIME type, encoding, charset and byte size.
- Copy the decoded text, or preview the image.
About this tool
ShowHide
Paste a data: URI and break it apart: the MIME type, whether the payload is Base64 or percent-encoded, the charset if one was declared, and the real size of the decoded bytes rather than the length of the string. That size is usually the reason you came — Base64 carries three bytes in four characters, so an inlined asset is about a third larger than the file it came from, which is what decides whether inlining is actually saving a request. Textual payloads such as text, JSON, XML, SVG, HTML and CSV are decoded and shown, and an image type gets a live preview. A URI with no MIME type at all falls back to text/plain, exactly as the specification says. Everything runs locally — nothing is uploaded.
Frequently asked questions
Which data URIs are supported?
Any RFC 2397 data: URI, with or without a media type, and either Base64 (;base64) or percent-encoded payloads. A missing media type defaults to text/plain.
How is the size calculated?
It is the real size of the decoded bytes, not the length of the encoded string — so it reflects the actual file or text size the URI represents.
Can it preview images?
Yes. When the MIME type is image/*, the decoded data is rendered as a live preview directly from the URI. Non-image binary payloads just show their size.
Is my data URI sent anywhere?
No. Decoding happens entirely in your browser; nothing is uploaded.
Is inlining an image as a data URI worth it?
For a small icon, often yes — one fewer request. Past a few kilobytes it stops paying: Base64 adds about a third to the byte count, the payload cannot be cached separately from the page that carries it, and it blocks nothing from being re-downloaded on every visit.
Why does a data URI with no MIME type still decode?
Because the specification supplies a default. A URI written as data:,Hello means text/plain with a US-ASCII charset, so the type is optional rather than missing. That default is also why a payload of unknown type is safer to declare explicitly than to leave off.
Related tools
Image to Base64
Convert an image to a Base64 data URL you can paste anywhere.
Image
URL Encoder / Decoder
Percent-encode text for URLs, or decode encoded URLs back to text.
Developer
Base64 Encoder / Decoder
Encode text to Base64 or decode Base64 back to text, instantly.
Developer
Relative URL Resolver (RFC 3986)
Resolve a relative reference against a base URI by RFC 3986, with the dot-segment trace and the browser’s answer beside it.
Network
URI Template Expander (RFC 6570)
Expand RFC 6570 URI templates with your own variables — all four levels, with path, query, fragment and label operators and explode modifiers.
Network
Protobuf Decoder (no .proto needed)
Paste base64 or hex protobuf bytes and read the fields — numbers, wire types, nested messages, strings and packed arrays — without a schema.
Developer