Nothing you open here is ever uploaded

Turn an image into a Base64 data URL

Nothing is decoded or re-encoded here: the bytes of the file are read and written out as text, prefix and all, so what comes back is the file you picked rather than a new version of it. That text is longer than the file, because Base64 spends four characters on every three bytes: worth it for an icon, rarely for a photograph.

This page loads no libraries at all. The work is done by the browser itself. Your file is read on your own machine and never sent anywhere. Open your browser’s network tab and watch while you use it.

Questions

Is the image re-compressed or changed in any way?

No. Unlike the other image tools here, this one never draws your picture on a canvas: the bytes are read and encoded as they stand. A JPEG stays the same JPEG, an SVG stays text, and an animated GIF is still animated when it comes out.

Does the result include the data: prefix?

Yes. What the Copy button gives you is a complete data URL, beginning with data: and the type your browser reports for the file, so it goes into a CSS url() or an img src with nothing to add. Cut the prefix off yourself if you need the raw Base64 on its own.

How much bigger does it get?

About a third. Base64 uses four characters for every three bytes, and the summary line puts the size of the file next to the length of the text it produced, so you can compare the two before you use it.

When is inlining worth it?

For small icons, where saving a request is worth the extra bytes. The larger the file, the worse the trade, and an inlined image cannot be cached on its own, so it travels again every time the file holding it changes.

Other images tools

Everything here is free and works the same way, in your browser.

New tools, once in a while

A new DeskKit tool lands every week or two. Leave an address to hear about it. Nothing else is ever sent, and one click removes you.