Base64 Encoder & Decoder

Convert text or files to Base64 and back, including the URL-safe variant you can drop straight into a query string.

Result

How to use

Type or paste text in the box above and the Base64 output appears below. To go the other way, switch to the decode tab and paste a Base64 string.

Turning on URL-safe output swaps plus and slash for hyphen and underscore and drops the trailing equals signs. That is the form you need when the value goes into a query string or a filename.

The file tab takes an image or a document and hands back the Base64 string for it, which is what you need to build a data URI or to send a file through a JSON API.

Nothing you type and no file you pick is sent to a server. Every conversion happens inside your browser.