Switching language reloads this page. Copy or save any inputs and results first.
26 / IMAGES
Image / Base64 converter
Images or URLs to Base64. Base64 back to images.
The destination must allow CORS. If the URL cannot be loaded, choose an image file.
Image preview
Files are not sent externally. Loading a URL connects only to the specified destination.
How to use, examples and questions
Convert images to Base64 or Data URLs and restore image files from Base64. Supports PNG, JPEG, WebP and GIF while preserving original image bytes. Image files are processed in your browser.
Image / Base64 converter — how to use
In “Image → Base64”, choose a file or enter an image URL and press “Load URL”.
Choose Data URL or Base64 only, then copy the result or save it as text.
For the reverse direction, paste into “Base64 → Image”, press “Convert to image” to preview, then save the image.
Input and output examples
Prepare an image for HTML / CSS
Settings: Image → Base64 / Data URL
Input
1 × 1 px のPNGファイル
Output
data:image/png;base64,iVBORw0KGgo…
This is an abbreviated display example. Actual output contains all image bytes and is usually about 33% larger than the original file.
Frequently asked questions
Why can't I load an image URL?
The source must allow CORS access from this site. Even public images need permission. Save the image locally and choose the file instead. Cookies and credentials are not sent.
Are GIF animation and image metadata preserved?
The original bytes are converted without recompressing the image, preserving GIF animation and original image information. Base64 is not encryption and does not hide image contents.
Can I convert SVG?
SVG and HEIC are unsupported. Limits: 20 MiB, 16,384 px per side and 25 million pixels. A mismatch between a Data URL's declared and actual image format also causes an error.
Specifications and limits
Supports PNG, JPEG, WebP, GIF and Data URLs. Maximum 20 MiB. URL sources must allow CORS. SVG is unsupported.
Analytics and privacy
Conversion inputs and results are processed in your browser. Image URL and OGP loads connect directly to your chosen destination only when you select the corresponding button. Image, video, Markdown, HTML, CSV and TSV files are not uploaded to our servers. Self-signed certificates and signatures are generated locally; private keys are never sent to our servers or analytics. Markdown external images and HTML scripts are not loaded. The API client sends the URL, headers, body and selected files directly to the endpoint only when you select Send or its shortcut. Speed tests exchange generated test data with Cloudflare when you start a measurement. These destinations receive your IP address. We do not proxy these connections or send inputs or measurement results to analytics. Conversions are not saved automatically. Unsaved API inputs, responses, history and environments stay only in this page. Only API requests explicitly selected with Save in this browser are stored. Auth fields, secret variables, known auth headers and files are excluded; review URLs, bodies and custom headers for other secrets first. Collection exports include URLs and bodies, so review them before sharing.
When analytics is enabled, we use Google Analytics 4 to measure pages, tool names and use counts, actions such as copying or saving an image, speed test starts, completion, cancellation and errors, product link clicks, and monitoring guide and service clicks using fixed IDs. Google uses cookies and collects device and browser information. Google signals for advertising and ad personalization are disabled.
Disabling analytics stores only that preference in this browser. Analytics settings never contain your inputs.Google's privacy policy