Image ↔ Base64 Converter

Drag & drop images here, or click to browse

Max 10 MB per file. Supports PNG, JPG, GIF, WEBP, SVG, BMP.

Settings

Insert line breaks every 76 characters (MIME)

What is Image ↔ Base64 Converter?

Image ↔ Base64 Converter is a free online tool that converts images to Base64 encoded strings and vice versa. It supports batch conversion of multiple images with drag-and-drop upload, multiple output formats (raw Base64, Data URI, HTML img tags, CSS backgrounds), and can decode Base64 strings back to downloadable images. Perfect for web developers embedding images directly in HTML/CSS or APIs.

How to use

Image → Base64: 1. Drag and drop images into the upload zone, or click to browse. 2. Choose your output format (Raw Base64, Data URI, HTML, CSS, Markdown). 3. Copy individual results or export all as TXT, JSON, HTML, CSS, or ZIP.

Base64 → Image: 1. Switch to "Base64 → Image" mode. 2. Paste your Base64 string or Data URI. 3. Click Decode to preview, then Download to save the image.

Supported Formats

  • Input: PNG, JPEG, GIF, WebP, SVG, BMP, ICO, AVIF (up to 10MB per file)
  • Output formats: Raw Base64, Data URI, `` tag, CSS `background-image`, Markdown
  • Export formats: TXT, JSON, HTML, CSS, ZIP
  • Auto-detection: MIME type detected from magic bytes for Base64 → Image decoding

Features

  • 100% client-side — your images never leave the browser
  • Batch processing — convert multiple images at once
  • Drag-and-drop upload with progress indicators
  • Multiple output format options with live preview
  • MIME line breaks option (76 chars) for email compatibility
  • Bulk export to TXT, JSON, HTML, CSS, or ZIP archive
  • Reverse mode: decode Base64 back to downloadable images
  • Image preview with zoom and rotate controls
  • Session persistence — your work is saved automatically

Use Cases

  • Embedding small images directly in HTML/CSS to reduce HTTP requests
  • Creating data URIs for inline SVG icons
  • Preparing image data for API payloads or JSON configurations
  • Email signatures with embedded images
  • Debugging Base64 encoded images by converting back to viewable format
  • Generating CSS sprite alternatives with Base64 backgrounds