All Tools Store
Runs in your browser

Base64 encode and decode

Turns text or a file into Base64 and turns Base64 back into readable text. Your file is never uploaded; the work happens on your device.

Result

Base64 is an encoding, not encryption — anyone can decode it. Don't use it to protect secrets. Everything runs in your browser: neither your text nor the file you pick is sent to a server.

How to use

  1. Choose Encode or Decode with the buttons above.
  2. Paste your text into the box, or press Choose a file to encode a file.
  3. Tick URL-safe if the result goes in a URL, or wrap at 76 for email and MIME.
  4. Take the result with Copy, or save it with Download.

What Base64 is

Base64 is an encoding that turns binary data into text made of 64 safe characters: A-Z, a-z, 0-9, + and /, with = at the end as padding.

It exists for a simple reason: much of the internet was built to carry text. Push raw binary through email, JSON, XML or HTML and it gets mangled. Base64 converts the data into harmless characters so it survives those channels intact.

The cost is size: every 3 bytes become 4 characters, so the data grows by about 33%. That's why Base64 is a poor way to move large files.

Where you'll meet Base64

Base64 is not encryption

This is the most common misunderstanding. Encryption involves a key, and without the key the data stays closed. Base64 has no key: anyone who sees the text can reverse it in seconds — including with this page.

In practice: a Base64-encoded password is a plaintext password. When you see Base64 in a config file, a URL or a message, don't treat it as secret. Data that genuinely needs hiding needs encryption.

Base64 doesn't guarantee integrity either. To check whether a file arrived unchanged, use the hash generator.

Standard, URL-safe and wrapped variants

VariantDifferenceUsed for
StandardUses + and /, ends with = paddingGeneral purpose
URL-safeUses - and _, drops =URLs, JWTs, file names
MIME (76)Wraps lines at 76 charactersEmail attachments

When decoding, this tool accepts all three automatically: it converts - and _, restores missing padding and ignores line breaks. You don't have to think about where you copied it from.

Text is always handled as UTF-8, so accented letters and emoji come back exactly as they went in.

Glossary

Base64
An encoding that represents binary data as text using a safe 64-character alphabet.
Padding
The trailing = characters, added to round the data up to a multiple of three bytes.
URL-safe Base64
A variant using - and _ instead of + and /, with no padding.
data: URL
A format that embeds a file's content directly in a URL, usually written in Base64.

Frequently asked questions

What is Base64?

An encoding that turns binary data into text made only of letters, digits and a couple of symbols, so that binary can travel safely through systems built for text — email, JSON, HTML.

Is Base64 encryption?

No. Encryption needs a key; Base64 needs nothing and anyone can reverse it. It is not suitable for storing passwords or personal data.

Is my file uploaded?

No. The file is read inside your browser and encoded there; its contents are never sent anywhere.

What is URL-safe Base64?

Standard Base64 uses + and /, which cause trouble inside URLs. The URL-safe variant uses - and _ instead and drops the trailing = padding. JWTs use this form.

Why is the result bigger than the original?

Base64 produces 4 characters for every 3 bytes, so size grows by about 33%. Line wrapping adds a few more characters.

Decoding gives me gibberish — why?

What you decoded probably isn't text but an image or another binary file. This tool shows decoded data as text, and binary files can't be read that way.

Do accented characters and emoji survive?

Yes. Text is encoded as UTF-8, so accented letters and emoji come back exactly as they went in.

Hash GeneratorMD5, SHA-1, SHA-256 and SHA-512 digestsText ToolsDedupe, sort, shuffle, find & replaceQR Code GeneratorQR for links, text, Wi-Fi and 2FA

the Mall of Accs team Last updated:

More free tools

2FA Code GeneratorInstant codes from your secret keyPassword GeneratorStrong random passwords, one or in bulkQR Code ScannerRead a QR code from an image or cameraImage to LinkUpload an image, get a shareable linkImage CompressorCompress, resize, convert JPG/PNG/WebPImage WatermarkAdd a text watermark to images in bulkGmail Dot & Alias GeneratorHundreds of addresses from one GmailAccount Line ParserTurn messy lines into clean columnsYouTube Channel IDUC channel ID from a URL or @handleFacebook UIDNumeric ID from a public profileInstagram User IDNumeric ID from a public profileTikTok User IDNumeric ID + secUid from a profileYouTube Link GeneratorTimestamp link, embed code, subscribe linkYouTube Tag ExtractorA video's tags, title and descriptionYouTube Logo & BannerDownload a channel's logo and bannerYouTube ThumbnailDownload a video cover image (HD)Earnings CalculatorYouTube/TikTok/Twitch/Spotify incomeEngagement RateEngagement % from followers + likesProfile Photo DownloaderTikTok & Instagram profile pictureWheel of NamesType names, spin the wheel, get a winnerGiveaway PickerPick a fair random winner from a listText CompareLine-by-line diff of two textsInstagram Bio Line BreakLine breaks that survive in bios and captionsFancy Text GeneratorBold, italic and fancy Unicode text stylesCharacter & Word CounterLive counts against platform limitsUTM Link BuilderAdd campaign tags to a linkBinary ConverterText ⇄ binary, decimal ⇄ hex ⇄ octalSlug GeneratorTurn a title into an SEO-friendly URLJWT DecoderRead what is inside a tokenTimestamp ConverterUnix time to date and backJSON FormatterFormat, minify, find errors by linePassword Strength CheckerHow long would it take to crack?User-Agent ParserBrowser, OS, device and bot detectionIP LookupIP owner, ASN and reverse DNSEmail Domain CheckerMX, disposable, SPF and DMARCOutlook / Hotmail Inbox ReaderRead the inbox of an account you boughtShort Link GeneratorShorten long links in one clickUnit ConverterLength, weight, temperature, data and moreStopwatch & TimerLaps, plus a countdown with a sound alertDiscount CalculatorPercent-off price and discount rateCurrency ConverterDollar, euro, lira and 30 currencies