Free online base64 encoder decoder. Paste text or add a text file, select Encode or Decode, then copy the Base64 result or download it as a file.
Encoding tools by OnlinePCApps since 2013
Some systems carry only plain text, yet the data to move is binary or full of odd characters. The free online base64 encoder decoder packs it into safe text and unpacks it again.
Email, JSON and many APIs were built for text, not raw bytes. Base64 turns data into safe characters that pass through those channels intact. The tool makes that string from pasted text or a text file, then decodes it back.
A Basic Auth header, a config entry or a small payload often needs a Base64 string. Type the text, select Encode to Base64 and copy the result straight into the header or file. No script is needed for a quick job.
A token, a config value or part of an API response often arrives as Base64. Decoding it with the online base64 encoder decoder shows the plain text inside, which helps when debugging a payload.
Paste text into the Source Content panel above, or select Upload to add a .txt, .b64, .json, .js, .md, .csv or .xml file. A file can also be dropped on the panel, and its text appears there.
Set Mode to Encode to turn text into Base64, or to Decode to turn a Base64 string back into plain text. Then select Encode to Base64 or Decode Base64 to run the online base64 encoder decoder.
Select Copy Result to send the output to the clipboard, or Download File to save it. Select Edit / Process Another to return to the input, or Reset All to clear everything and start over.
To encode is to rewrite bytes as safe text, and to decode is to turn them back. The online base64 encoder decoder does both from one panel.
Text is encoded into a Base64 string, and a Base64 string is decoded back to plain text. A Mode menu switches the same panel between Encode and Decode, so one tool covers the round trip.
Type or paste text, or select Upload to add a .txt, .b64, .json, .js, .md, .csv or .xml file. The tool takes text only, so images, PDFs and other binary files are not supported.
The output uses the standard alphabet, with plus and slash. There is no URL-safe option and no padding setting. For a JWT or a web address, swap plus and slash for minus and underscore by hand.
Copy Result sends the output to the clipboard. Download File saves it as a .b64.txt file after Encode and a .txt file after Decode. Edit / Process Another returns to the input and Reset All clears everything.
To encode Base64, to decode Base64 and to turn text into a Base64 string all name one task. A search for base64 encoder or base64 decoder lands on the online base64 encoder decoder above.
Base64 rewrites bytes as safe text and turns them back. The cases below show what the tool does and where it stops.
| The case | Result | What happens and why |
|---|---|---|
| Alphabet | 64 characters | A to Z, a to z, 0 to 9 with plus and slash, the set defined by RFC 4648. |
| Standard output | plus and slash | The output uses the standard alphabet only. |
| URL-safe variant | not on this page | There is no URL-safe option. For a URL or a filename, swap plus for minus and slash for underscore by hand. |
| Padding | = signs | A short last block ends in one or two equals signs under RFC 4648. There is no setting to keep or trim them. |
| Size | about +33% | The encoded text is roughly a third larger, four characters for every three bytes. |
| Text input | paste or file | Paste text, or select Upload to add a .txt, .b64, .json, .js, .md, .csv or .xml file. |
| Binary files | not supported | Images, PDFs and other binary files fall outside the accepted list. Use the base64 command for those. |
| Data URI | not on this page | No data URI prefix is added. Type the prefix by hand when a string must embed in CSS or HTML. |
| Decode output | plain text | Decode returns plain readable text and Download File saves a .txt file. Check any binary result before trusting it. |
| Not encryption | reversible | Base64 hides nothing, since anyone can decode it. It is encoding, not security. |
| Round trip | check it | Encode a sample, paste the result and select Decode to confirm a match. Try accents or emoji on a short line first. |
| Bad input | message shown | An empty panel shows Please enter text or upload a file first. A failed run shows an error message and no output. |
| Big input | check it | Size limits are not stated on this page. Test a large input first, and use the base64 command for huge files. |
| Where it runs | on the device | The data is encoded in the browser, so nothing is uploaded. |
How Base64 Works
Base64 is a way of writing binary data using only 64 printable characters. It takes three bytes at a time. That is twenty-four bits, and it splits them into four groups of six bits, with every group mapped to one character from the alphabet A to Z, a to z, 0 to 9, plus and slash. Where the input does not divide evenly, one or two equals signs pad the end. This is why the encoded text runs about a third larger than the original, four characters for every three bytes. RFC 4648 sets the rules and also defines a URL-safe variant, though the online base64 encoder decoder gives the standard alphabet only. One honest point matters above the rest. Base64 is encoding, not encryption. It hides nothing, because anyone can decode it back with no key, so it carries data through a text channel and never protects a secret. The references below define the standard.
Both encode and decode Base64. The trade is real, and a token is often a secret.
| Point of comparison | This tool Online encoder decoder In the browser | The command line A local terminal tool |
|---|---|---|
| Where the data goes | Stays on the device | Stays on the machine |
| Price and caps | Free with no sign-up | Free tier often capped |
| A huge file | Check the size limit | Streams from disk |
| Pipe into a script | A paste at a time here | Part of an automated build |
| Nothing to set up | Open the page and paste | A terminal and its flags |
The command line wins for a huge file or a step inside an automated build, where the base64 utility fits a pipeline. The online base64 encoder decoder wins for a quick encode or decode with a preview and nothing to install. Online file tools and whether yours uploads goes deeper on where a pasted token goes.
The text or the file is encoded and decoded inside the browser with plain JavaScript, so the work is client-side and the data stays on the machine that opened it. No copy is passed to a server for the job.
A Base64 string often carries a token, a key or a config value never meant for an outside server. A hosted encoder has to upload the input to process it, and since Base64 is reversible, that exposes whatever the string holds.
All of these encode or decode Base64. They differ in effort, in cost and in setup.
The command line and a code one-liner both encode Base64, yet both need a terminal or a program. The online base64 encoder decoder above encodes and decodes with a preview and nothing to set up.
Keep these in mind for a clean result.
Base64 hides nothing, since anyone can decode it back with no key. Treat the output as open to anyone who sees it. For real protection, encrypt the data first.
The tool gives standard Base64, with plus and slash. Those two characters break in a web address, a filename or a JWT, so swap them for minus and underscore by hand when the string goes there.
Base64 adds about a third to the size, four characters for every three bytes. That is fine for a small asset or a token, but a large file is usually better sent as a raw attachment than an inline string.
The online base64 encoder decoder handles one input per run, which suits an everyday paste. A huge file, or a folder of assets encoded inside an automated build, belongs on the base64 command or the desktop edition.
Point it at a folder of assets and every one is encoded to Base64 or a data URI in a single run, saved beside the source.
A file of hundreds of megabytes is streamed from disk and encoded, past what a browser tab keeps in memory at once.
A saved step encodes assets into a bundle as part of a build, ready for a repeated pipeline with no manual paste.
No sign-up needed. Paste text into the online base64 encoder decoder, then select Encode or Decode.