// free ยท runs in your browser ยท nothing uploaded
Base64 Encoder & Decoder
Encode and decode Base64 and Base64URL with full UTF-8 support. Turn images and files into data URLs for HTML and CSS, or turn Base64 back into a file you can preview and download.
๐ Official sources: Base64 standard (RFC 4648)
We build every tool from the official rules and re-check them when they change. Always confirm with the official source before you rely on a result.
๐ ๏ธ Spotted a mistake or an out-of-date rule? Tell us
How it works
Text is first turned into UTF-8 bytes. Every 3 bytes (24 bits) are then split into four 6-bit groups, and each group picks one of 64 characters. If the last group is short, = signs pad it. Decoding runs the same steps backwards, and the tool checks whether the bytes are readable text or a file, so it can offer a download instead.
Example
รnรฏcode โ ๐ is 18 bytes in UTF-8 and encodes to w5xuw69jb2RlIOKckyDwn5qA. Decoding SGVsbG8= gives Hello; the one = shows the last group held only 2 bytes.
Good to know
- Base64 makes data about a third bigger, so a 300 KB image becomes about 400 KB as a data URI; inline only small images.
- Line breaks every 76 characters (MIME style) are fine to paste; the decoder ignores whitespace.
Guides
Related tools
Questions people ask
What is Base64?+
Base64 turns any data, such as text, an image or a file, into plain letters and numbers (AโZ, aโz, 0โ9, + and /). It is used to put images inside HTML or CSS, to send files in email and JSON, and in tokens such as JWTs.
Is Base64 encryption?+
No. Anyone can decode Base64 in a second, so never use it to hide passwords or secrets. It only changes the format of the data.
What is Base64URL?+
A version that is safe inside web addresses and file names: + becomes -, / becomes _, and the = padding at the end is dropped. JWTs use it. This decoder reads both kinds automatically.
Does it work with emoji and other languages?+
Yes. Text is encoded as UTF-8, the standard used on the web, so emoji, accents, Arabic, Urdu, Hindi and every other script come back exactly the same.