Processed in your browser. Your file is not uploaded.
Your Base64 string will appear here
Pick an image and copy it as a data URL you can paste straight into CSS or HTML.
Encode an image as Base64 locally in your browser and copy the resulting data URL.
How it works
For CSS, HTML, JSON payloads and quick tests.
The file is read locally with the File API.
A data URL is ready to paste into src or CSS; plain Base64 is the raw string without the prefix.
Copy the result in one click or download it as a .txt file.
More free browser tools on Nano Banana Lab.
Base64 stores three bytes as four characters, so the string is about a third larger than the binary file.
For small icons and placeholders that should not cost an extra request, and for APIs that accept images as text.
The tool accepts files up to 50 MB, but very large images produce strings that are painful to handle — keep it to small graphics.
No. The encoding happens in your browser.