🔒 100% client-side — your files never leave your browser

Base64 Converter

Instantly encode any file to a Base64 string, or decode a Base64 string back to a downloadable file. Free, private, no sign-up.

⚡ Instant
🔒 Private
📁 Any file type
🎯 No limits

Encode File to Base64

Drop your file here

or browse files

Any file type supported — images, PDFs, documents, binaries

How the Base64 Converter Works

1

Select or Drop a File

Drop any file — image, PDF, document, video, or binary — into the encode panel. The tool reads your file entirely in the browser using the FileReader API.

2

Instant Encoding

Your file is instantly converted to a Base64 string. You can optionally include the data URI prefix (e.g. data:image/png;base64,) for direct use in HTML, CSS, or JSON.

3

Copy or Download

Copy the Base64 string to your clipboard or download it as a .txt file. To reverse, paste the Base64 string in the Decode tab and download the original file.

Frequently Asked Questions

What is Base64 encoding?

Base64 is a binary-to-text encoding scheme that represents binary data as a sequence of printable ASCII characters. It is commonly used to embed files (images, fonts, icons) directly into HTML, CSS, or JSON without needing a separate HTTP request.

Is my file uploaded to a server?

No. All encoding and decoding happens entirely in your browser using the Web File API and JavaScript. Your files are never sent to any server. This makes the tool completely private and secure.

What file types are supported?

All file types are supported — images (PNG, JPG, SVG, GIF, WebP), documents (PDF, DOCX), audio (MP3, WAV), video (MP4), binaries, archives (ZIP), and more. Base64 encoding is a universal binary-to-text method that works on any file.

What is the data URI prefix?

A data URI prefix looks like data:image/png;base64, and prepends the MIME type to the Base64 string. This format can be used directly in an HTML img src, CSS background-image, or any context expecting a URL. Toggle the option in the output panel to include or exclude it.

How big can the file be?

There is no hard limit imposed by this tool. However, very large files (hundreds of MB) may be slow to process depending on your device, as encoding happens synchronously in the browser. For most use cases (images, PDFs, documents), performance is instant.

How do I decode Base64 back to a file?

Switch to the "Decode Base64 → File" tab, paste your Base64 string (with or without the data URI prefix), enter a filename with the correct extension, and click "Decode & Download". The file will be reconstructed and downloaded immediately.