Skip to content

Developer tools

Base64 Encode & Decode

Encode and decode Base64 text (with emoji and any language), switch to URL-safe Base64, or turn a file into a data URI.


        

File to Base64 data URI

For embedding small images or fonts in CSS or HTML (up to 10 MB).


        

How to use the Base64 Encode & Decode

  1. 1

    Choose Encode or Decode.

  2. 2

    Type or paste your text, or choose a file to get its Base64 data URI.

  3. 3

    Copy the result. Tick "URL-safe" for tokens and URLs.

Frequently asked questions

Is Base64 encryption?

No. Base64 only changes how data is written so it fits in text (emails, JSON, URLs). Anyone can decode it, so never use it to hide secrets.

What is URL-safe Base64?

It replaces + and / with - and _ and drops the = padding, so the value can go in URLs and file names. JWTs use it.

Embed this tool on your site

Paste this code into your page. It's free, with no sign-up, ads or cookies.

Preview

Please keep the "Powered by Dev-Talk" link.

Get new articles in your inbox

Practical tutorials and deep dives, about once a week. No spam, unsubscribe anytime.

Privacy policy

Add DEV Talk to your Home Screen

  1. 1 Tap the Share button in Safari's toolbar.
  2. 2 Scroll down and tap Add to Home Screen.
  3. 3 Tap Add. Open it from the Home Screen to read like an app and to turn on notifications with the bell.

We use cookies to improve your experience and analyze traffic. By continuing, you agree to our Privacy Policy.