Image to Base64

Convert image to base64 string.

Click or drag and drop

PNG, JPG, WebP, etc.

Result

Related tools

How it works

  1. 1Upload an image (PNG, JPG, WebP, etc.).
  2. 2The tool reads the file and converts it to a Base64-encoded data URL.
  3. 3Output format: data:image/png;base64,iVBORw0KGgo...
  4. 4Copy the string to embed in HTML img src or CSS.

Example

Input: [upload image]
Output: data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNk+M9QDwADhgGAWjR9awAAAABJRU5ErkJggg==