DevTools Party Preloader Image

Base64 Decoder

Convert your Base64 string to its original form

Use this free online tool to decode your Base64 encoded strings into its original form. Fast, secure, and easy to use. No registration or installation required.

Base64 Decoder - Convert Base64 encoded strings to the original form instantly

Base64 decode

The Base64 Decoder is a simple and efficient online tool that converts Base64-encoded strings into its not encoded form (the original one). Base64 decoding is commonly used to decode data after a transmittion in formats that require text-based representations, such as JSON, XML, or URL parameters.

How Decoding Works

Base64 decoding reverses the encoding process, converting the encoded ASCII characters back into their original binary form. This ensures that the original data can be accurately retrieved after transmission through text-based protocols. The decoding process follows these fundamental principles:

  • It maps each encoded character back to its corresponding binary value based on the predefined Base64 table.
  • The decoded output reconstructs the original data by grouping bits together in their original form.
  • Padding characters (=) at the end of the encoded string are removed to correctly restore the original data size.
  • The result is a faithful restoration of the raw input, making it usable in its intended format.

Af per the encoding process, different implementations are possible. As an example "RFC 4648" defines the characters set as only letters (A-Z, a-z) and numbers (0-9) for the first 62 characters, and plus (+) and slash (/) symbols as last 2 characters - padding equal symbol (=) is used when necessary. "RFC 4648 / Base64URL" variant differs from the previous one for the last 2 character. It uses minus (-) and underscore (_) as they are URL safe.

Common Use Cases

  1. Data Transmission & Storage
    • Ensures safe transmission of binary data over text-based protocols like email (MIME) and HTTP.
    • Stores binary files (e.g., images, PDFs) as text in JSON, XML, or databases.
  2. Encoding Credentials & Tokens
    • Used in Basic Authentication headers (Authorization: Basic <Base64-encoded credentials>).
    • Encodes API keys, session tokens, and other authentication-related data.
  3. Embedding Binary Data in Text-Based Formats
    • Converts images, audio, or documents into a text format for inclusion in HTML, CSS, or JavaScript.
    • Used in Data URLs (data:image/png;base64,...) to embed media directly in web pages.
  4. Serialization & Data Persistence
    • Stores binary data in text-friendly formats when serializing data in JSON, YAML, or XML.
    • Helps when transferring structured data across different systems.
  5. Cryptography & Hashing
    • Encodes cryptographic signatures, certificates, and keys (e.g., PEM format for SSL certificates).
    • Stores and transmits hashed or encrypted data safely.
  6. Avoiding Special Character Issues
    • Ensures safe encoding of binary or special characters that might get corrupted in URLs, cookies, or command-line arguments.
    • Prevents character encoding issues in legacy systems or different text encodings.

While Base64 is useful for encoding and transmission, it's not encryption—it provides no security and can be easily reversed through decoding.

How to Use

Enter your encoded string: input or paste the string you want to decode into the input field.
Decode: click the "Decode" button to convert the string.
Get the result: copy the Base64-decoded result for use it.

This tool ensures quick and reliable Base64 decoding, making it a must-have utility for developers working with data serialization, APIs, or web applications.

The conversion process (decoding)

To convert a Base64 encoded string into its original format we need to follow the opposite process used for the encoding. The process' steps are the following and represent the Base64 decoding algorithm:

Convert each Base64 character into its corresponding index from the Base64 table (e.g., 'T' is 19, 'm' is 38).
Convert each index into its 6-bit binary equivalent (e.g., 19 → 010011, 38 → 100110).
Concatenate all 6-bit binary sequences and regroup them into 8-bit chunks (bytes).
Convert each 8-bit binary sequence into its ASCII character representation to reconstruct the original data.

Let's have a pratical example. For example decode the string RmF0aGVy.

Encoded string RmF0aGVy
Base64 characters R m F 0 a G V y
Index 17 38 5 52 26 6 21 50
Binary 0 1 0 0 0 1 1 0 0 1 1 0 0 0 0 1 0 1 1 1 0 1 0 0 0 1 1 0 1 0 0 0 0 1 1 0 0 1 0 1 0 1 1 1 0 0 1 0
ASCII 70 97 116 104 101 114
Original F a t h e r

Obtaining the Father string like in the famous phrase:

I am your Father

Base64 table from RFC 4648

Base64 Table 1/4
Index ASCII
0 A
1 B
2 C
3 D
4 E
5 F
6 G
7 H
8 I
9 J
10 K
11 L
12 M
13 N
14 O
15 P
Base64 Table 2/4
Index ASCII
16 Q
17 R
18 S
19 T
20 U
21 V
22 W
23 X
24 Y
25 Z
26 a
27 b
28 c
29 d
30 e
31 f
Base64 Table 3/4
Index ASCII
32 g
33 h
34 i
35 j
36 k
37 l
38 m
39 n
40 o
41 p
42 q
43 r
44 s
45 t
46 u
47 v
Base64 Table 4/4
Index ASCII
48 w
49 x
50 y
51 z
52 0
53 1
54 2
55 3
56 4
57 5
58 6
59 7
60 8
61 9
62 +
63 /