Files tool

Image-to-Base64 Converter

Turn an image into a Base64 data URL or CSS-ready value without uploading it.

Runs in your browser
Image-to-Base64 Converterno upload

Base64 usually makes files roughly one-third larger. Prefer normal image files for large photos.

How to use this image-to-base64 converter

  1. Choose an image, then copy the complete data URL or the CSS-ready value.
  2. Check the preview, dimensions, format, and file size before downloading. Open the saved image once to make sure it works.
  3. Preview the finished file, then download it. Open the download once to make sure it has the expected size and content.

About this image-to-base64 converter

Use the Image-to-Base64 Converter to turn an image into a Base64 data URL or CSS-ready value without uploading it. Change the inputs to compare another result.

You can also use it to compare the converted result with the source.

Example

Choose a small PNG icon and copy its data:image/png;base64 value into CSS, HTML, or a test fixture.

Common uses

  • turn an image into a Base64 data URL or CSS-ready value without uploading it
  • compare the converted result with the source
  • prepare the output for another task or program