Find your next tool

Browse tools or search by task

Explore JSONToonPro

Encoding & Decoding Tools

Base64 to JSON Decoder Online

Decode Base64 strings into readable JSON online. Validate and pretty print decoded objects for JWT payloads and API data in your browser.

Runs locally in your browser. Nothing you paste is uploaded.

Base64 to JSON workspace
Base64 Input
0 chars
JSON Output
Result appears here...

How to Decode Base64 to JSON

Paste the encoded payload and select Decode. The bytes are decoded as UTF-8 and parsed as JSON before pretty printing. If the text is not valid JSON, the tool reports that distinction instead of presenting arbitrary text as a JSON document.

Recognizing Base64-Encoded JSON

Encoded JSON often decodes to an object or array, but a prefix is not a reliable validator. Base64 can represent any byte sequence. Decode the full payload, then validate its actual content.

Base64URL and JWT Payloads

JWT header and payload segments use Base64URL. Decode a single segment here or use JWT Decoder for the whole token. A successfully parsed payload does not verify a signature or establish that claims are trustworthy.

Validating Decoded JSON

Pretty printing confirms that the decoded text parses. It does not establish required fields or application-level validity. Use JSON Schema Validator when a data contract needs to be checked.

Common Decode Errors

A decoding error differs from a JSON parse error: one concerns Base64 or UTF-8, the other JSON syntax. Check missing characters, wrapper prefixes and the selected segment. Some Base64 strings simply do not contain JSON.

More examples and technical details

When You Need Base64 to JSON

Most people arrive at this conversion for one of three reasons: they are inspecting a JWT payload during authentication debugging, they have received an API response whose body or cursor is an opaque encoded blob, or they are reading a configuration value that was flattened into a single line so it could live in an environment variable. In every case the underlying content is ordinary JSON that was wrapped for transport.

The tell is almost always the same. A long string of letters and digits that starts with eyJ is Base64 encoded JSON, because the opening brace and quote of a JSON object always encode to that prefix. Once decoded, formatting the result makes nested claims and arrays readable at a glance.

Reading a JWT Payload

A JSON Web Token is three segments joined by dots. The first two are Base64URL encoded JSON and can be read by anybody. The third is a cryptographic signature over the first two and is meaningless as text.

eyJhbGciOiJIUzI1NiJ9 . eyJzdWIiOiIxMjMifQ . dBjftJeZ4CVP-mB92K27uhbUJU1p1r_wW1gFWFOEjXk
^ header ^ payload ^ signature
 
header decodes to {"alg":"HS256"}
payload decodes to {"sub":"123"}
  1. Copy the token and locate the two dot separators.
  2. Take the middle segment, the text between the two dots.
  3. Decode it as Base64URL to get the raw JSON claims object.
  4. Format the JSON and read the claims, starting with exp and aud.

Base64URL: What Changes

JWT segments use the URL and filename safe alphabet, so a strict standard decoder can reject them. Three differences matter:

1. index 62 is - instead of +
2. index 63 is _ instead of /
3. trailing = padding is normally stripped
 
Repair recipe before decoding:
replace - with +
replace _ with /
append = until the length is a multiple of 4
 
length % 4 == 2 -> add ==
length % 4 == 3 -> add =
length % 4 == 1 -> the string is malformed

Common Claims You Will See

RFC 7519 registers a small set of claim names. Everything else in a payload is application specific, such as email, roles, scope, or tenant.

ClaimNameMeaning
issIssuerIdentifies the party that created and signed the token.
subSubjectThe principal the token is about, usually a user id.
audAudienceThe recipients the token is intended for. Reject if you are not listed.
expExpiration timeUnix timestamp after which the token must be rejected.
nbfNot beforeUnix timestamp before which the token must be rejected.
iatIssued atUnix timestamp recording when the token was created.
jtiJWT IDUnique identifier, useful for replay detection and revocation lists.

The time based claims (exp, nbf, iat) are Unix timestamps in seconds, not milliseconds. A value like 1735689600 is January 1, 2025. Multiplying by 1000 before feeding it to a JavaScript Date is a step people forget constantly.

Decoding Is Not Verifying

Anyone can read a JWT payloadDecoding a token requires no key and proves nothing. The payload is encoded, not encrypted, so never store passwords, private keys, or sensitive personal data in it. Equally, never trust a decoded payload in application logic until the signature has been verified server-side with the correct key and the expiry has been checked.

The Base64 Alphabet

Every 6 bit group produces a value between 0 and 63, and that value is looked up in the table below. RFC 4648 fixes this ordering: uppercase letters first, then lowercase, then digits, then the plus and slash characters. The padding character (=) is not part of the alphabet, it only marks the end of an incomplete group.

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

Working on something related? Browse every free developer tool on the site, including a JWT decoder, JSON formatter, JSON to Base64 encoder, and URL decoder. Everything runs entirely in your browser, so nothing you paste is ever uploaded.

Standards and references

Frequently asked questions

How do I decode Base64 into JSON?

Paste the Base64 payload and use Decode; valid JSON is printed readably.

Can this inspect JWT payloads?

It can inspect an individual encoded JSON segment. Use JWT Decoder for a complete token.

What if the decoded value is not valid JSON?

It reports invalid decoded JSON; use the general Base64 decoder if ordinary text is expected.

Does it support Base64URL?

Yes. URL-safe characters and omitted padding are normalized.

Is data uploaded?

No. Input is processed in this browser tab and is not uploaded by the tool. Copy and download are actions you control; ordinary page analytics do not receive tool input.