画像を Base64 に変換 オンライン

画像をアップロードして Base64 エンコード文字列またはデータ URL を即座に取得します。

クリックまたは画像をここにドラッグ&ドロップ

PNG、JPEG、GIF、WebP、SVG、BMP に対応

What Is Image to Base64 Converter?

Image to Base64 Converter is a free online tool that encodes any image file into a Base64 string or data URL. The encoded output can be embedded directly into HTML, CSS, or JSON — eliminating the need for a separate image file. It is commonly used for embedding small icons, logos, and thumbnails in web pages and API payloads.

How to Use Image to Base64 Converter

  1. Click the drop zone or drag and drop an image file onto it.
  2. The tool instantly encodes the image and displays both the full data URL and the Base64-only string.
  3. Click Copy next to either output to copy it to your clipboard.

Features

  • Supports PNG, JPEG, GIF, WebP, SVG, BMP, and more
  • Outputs both full data URL and Base64-only string
  • Drag-and-drop or click-to-upload interface
  • Image preview with file name and size
  • Runs entirely in your browser — zero data uploaded

FAQ

What image formats are supported?

The tool supports all common image formats including PNG, JPEG, GIF, WebP, SVG, and BMP.

What is the difference between a data URL and Base64?

A data URL includes the MIME type prefix (e.g. data:image/png;base64,...) and can be used directly in HTML img src or CSS background-image. The Base64-only string is just the encoded data without the prefix.

Is my image uploaded to a server?

No. The image is read and encoded entirely in your browser using the FileReader API. Your image never leaves your device.