Data URI Generator
Encode any file or text as a data URI for embedding in HTML, CSS, or XML.
data:text/plain;base64,
An external image or font file means an extra HTTP request before a page can fully render it, and for something small, a tiny icon, a background pattern, a custom font file, that round trip is often unnecessary overhead a data URI avoids entirely by embedding the file's actual bytes directly into the HTML, CSS, or XML that references it. This tool encodes any file or text as a complete data URI, with the correct MIME type prefix already attached, ready to paste straight into a src attribute or a CSS url() function rather than left as a raw, unlabeled base64 string.
See moreSee less about the Data URI Generator
Useful for embedding a small icon directly inside a CSS file so it loads with zero extra requests, inlining a custom font for an email template that can't reference external files, or turning any file into a single copyable string for pasting into source code.
Key features
- Clean interface
- Fast processing
- No signup required
- Works offline