Skip to content
Tool Dock

Image to Base64

Convert an image to a Base64 data URI for HTML, CSS or JSON.

Options
0 characters

Output

or press ⌘/Ctrl + Enter
  • Runs in your browser
  • Nothing is uploaded
  • Free, no sign-up

How to use it

  1. Choose an image file.
  2. Keep Data URI on so the result starts with data:image/...;base64, and can be pasted straight into HTML or CSS.
  3. Run it and copy the result.

Why Tool Dock

  • FastEverything runs on your own device, so there is no queue and no waiting for uploads.
  • PrivateYour files and text never leave the browser. Close the tab and they are gone.
  • Batch friendlyDrop several files at once and download each result, or all of them together.

Questions

When should I embed images as Base64?

For tiny icons and placeholders where saving an HTTP request matters. Larger images are better served as files: Base64 is about a third bigger and cannot be cached separately.

Is there a size limit?

Only your browser's memory. Very large images produce strings that editors and style sheets handle badly, so keep embedded images small.

All tools