HEIC to Base64 Converter
Batch convert HEIC images to Base64 encoded strings
Drop your iPhone HEIC photos here and get Base64 data URLs back — ready to paste into <img> tags, CSS backgrounds, or API payloads. No format juggling, no two-step process. The tool decodes HEIC to PNG and encodes it as a data:image/png;base64,... string in one shot. And everything runs in your browser. Nothing gets uploaded.
How It Works
The heic2any library reads your HEIC file and converts it into a PNG blob. Then the browser’s built-in Canvas API reads that blob and outputs a Base64-encoded data URL. The whole thing takes a couple seconds per image — even less for smaller files. Batch mode processes multiple photos back to back so you don’t have to babysit each one.
Examples
Embedding an iPhone photo in an email template
Your marketing team sends you a product shot taken on an iPhone 15. The email builder only accepts inline images or Base64.
product-hero.heic (2.4 MB)
data:image/png;base64,iVBORw0KGgo...
(~3.2 MB string, ready for <img src="...">)
Sending a thumbnail through a JSON API
Your app’s API expects a Base64 image string in the request body. The user uploaded a HEIC selfie as their profile picture.
selfie.heic (1.1 MB)
data:image/png;base64,iVBORw0KGgo...
Paste into {"avatar": "..."} payload
Batch converting event photos for a static site
You shot 8 photos at a company event on your iPad. The static site generator needs inline images because there is no image hosting. Drop all 8 at once and grab every Base64 string in one copy.
event_001.heic through event_008.heic
(8 files, ~18 MB total)
8 Base64 data URLs
Use "Copy All" to grab them at once
Who Uses This
Embedding iPhone photos as inline Base64 in HTML templates or CSS without setting up image hosting.
Converting product shots from iPhones into Base64 strings that work in email builders with no external image links.
Turning HEIC uploads into Base64 payloads for REST APIs that don’t handle Apple’s image format.
Quick Base64 strings for homework projects or portfolio sites where they can’t host images separately.
Common Mistakes
Base64 adds about 33% to the data size, and HEIC-to-PNG conversion already inflates things because PNG is lossless. A 3 MB HEIC can become a 10+ MB Base64 string. Stick to thumbnails and small images — anything over 500 KB as HEIC probably isn’t a great candidate for inline embedding.
The output includes data:image/png;base64, at the start. If you strip that prefix before pasting into an <img src> tag, the browser won’t know what to do with the raw string. Keep the full data URL intact.
Changing a file extension doesn’t change the format. If someone renamed a JPEG to .heic, the HEIC decoder will fail because the file isn’t actually HEIC. Make sure your source files are genuine HEIC images — typically straight from an iPhone or iPad camera.
Technical Details
- Processing: 100% client-side — nothing leaves your browser
- Decoder: heic2any JavaScript library
- Output Format: PNG-based Base64 data URL (data:image/png;base64,...)
- Batch Support: Multiple files at once with Copy All
- Browser Support: Chrome, Firefox, Safari, Edge
Frequently Asked Questions
Can I convert HEIC to Base64 without installing software?
Yes. This tool runs entirely in your browser — no downloads, no installs, no accounts. Open the page, drop your HEIC file, and you’ve got a Base64 string in seconds.
Why is the Base64 output so much larger than the original HEIC?
Two things happen. First, HEIC uses aggressive compression that PNG doesn’t match — so the raw image data grows. Then Base64 encoding adds another 33% on top. A 2 MB HEIC can easily become a 7-8 MB Base64 string. That’s normal, but it means Base64 is best for smaller images.
Is it safe to convert HEIC photos online?
With this tool, yes. Your images never leave your device. The conversion happens right in your browser using JavaScript. No server sees your files, and nothing gets stored or logged anywhere.
How do I use a Base64 image in HTML?
Copy the full output string (starting with data:image/png;base64,) and paste it as the src attribute of an <img> tag. Like this: <img src="data:image/png;base64,iVBORw0...">. The browser renders it without needing a separate image file.
Can I convert multiple HEIC files to Base64 at once?
Absolutely. Drag a batch of HEIC files into the drop zone or select multiple files from the file picker. Hit "Convert All" and each one gets its own Base64 string. The "Copy All" button grabs every result into your clipboard in one go.
Convert HEIC images from your iPhone to Base64 encoded data URL strings. Perfect for embedding in HTML img tags, CSS backgrounds, JSON APIs, and emails. Copy individual results or all at once. All processing runs in your browser — nothing is uploaded to any server.