File to Base64 Converter
Turn any file into Base64 text or a ready-to-paste data URI — and convert it back to a file again.
Everything happens in your browser, so even large files stay on your device. Data URIs let you embed a file directly in HTML or CSS without a separate request — useful for small icons, wasteful for anything large.
Frequently Asked Questions
What is a data URI?
A way of embedding a file directly in HTML or CSS, as data:[mime];base64,[data]. The browser treats it as a real file with no separate request. Handy for small icons, wasteful for anything large.
Why does Base64 make my file bigger?
It encodes every three bytes as four characters, so the result is about 33% larger. That overhead is the price of representing binary data as safe text.
Is there a file size limit?
Only your device's memory, though very large files produce enormous strings that are awkward to paste anywhere. Above a megabyte or so, a data URI is rarely the right tool.
Can I decode a full data URI?
Yes. Paste the whole thing including the data:...;base64, prefix and it is stripped automatically before decoding.