Tools

Home
JSON FormatterSQL FormatterJS ValidatorMinify CSS
Merge PDFCompress PDFImage to PDF
JPG to PNGPNG to WebPCrop Image

Convert Base64 to JSON

Decode Base64-encoded text to JSON. Paste Base64, get formatted JSON output instantly. 100% client-side.

Your files never leave your browser
Base64 Input0 chars, 0 lines
JSON Output0 chars, 0 lines
Error:
    Ready·

    Paste a Base64 string, get formatted JSON back in one step — no decoding first, then formatting separately. Pick your indentation, copy the output, or download it as a .json file.

    Works with JWT payloads, API responses, webhook data, and any Base64-encoded JSON blob. Bad input gets a clear error so you know exactly what went wrong. And everything runs in your browser. Nothing gets uploaded.

    How It Works

    Paste Base64
    ➔
    Decode & Parse
    ➔
    Formatted JSON

    The tool takes your Base64 string and runs JavaScript's built-in atob() to decode it into raw text. Then it feeds that text through JSON.parse() to validate the structure, and finally pretty-prints the result with JSON.stringify() using your chosen indentation. If either step fails, the error message tells you which one — bad Base64 or bad JSON.

    Examples

    Simple API Response

    A config endpoint returned this Base64 blob in a webhook payload. Quick decode to see what's inside.

    INPUT
    eyJuYW1lIjoiSm9obiIsImFnZSI6MzB9
    OUTPUT
    { "name": "John", "age": 30 }

    JWT Token Payload

    You split a JWT at the dots and want to read the middle section — the claims payload.

    INPUT
    eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkphbmUgRG9lIiwicm9sZSI6ImFkbWluIiwiaWF0IjoxNjE2MjM5MDIyfQ==
    OUTPUT
    { "sub": "1234567890", "name": "Jane Doe", "role": "admin", "iat": 1616239022 }

    Nested Array from a Database Export

    A database stored JSON as a Base64 blob in a text column. You exported the row and need to see the actual data structure.

    INPUT
    eyJvcmRlcnMiOlt7ImlkIjoxMDEsIml0ZW0iOiJLZXlib2FyZCIsInByaWNlIjo3NS41MH0seyJpZCI6MTAyLCJpdGVtIjoiTW91c2UiLCJwcmljZSI6MjkuOTl9XX0=
    OUTPUT
    { "orders": [ { "id": 101, "item": "Keyboard", "price": 75.50 }, { "id": 102, "item": "Mouse", "price": 29.99 } ] }

    Who Uses This

    💻 Backend Developers

    Decoding Base64 payloads from webhooks, message queues, or API logs during debugging.

    🔐 Security Engineers

    Inspecting JWT claims and Base64-encoded tokens without trusting a third-party site.

    📊 QA Testers

    Verifying that API responses contain the right JSON structure before it gets Base64-wrapped in transit.

    📚 Students

    Learning how Base64 encoding works by seeing the raw JSON that comes out the other side.

    Common Mistakes

    Pasting the entire JWT instead of just the payload

    A JWT has three parts separated by dots: header.payload.signature. Only the middle part is Base64-encoded JSON. Paste the whole token and you'll get a decode error. Split at the dots first.

    Including line breaks or whitespace in the Base64

    Some email clients and logs wrap long Base64 strings across multiple lines. Those newlines aren't part of the actual data. Remove them before converting or you will get an "invalid character" error.

    Expecting non-JSON data to parse

    Not every Base64 string decodes to JSON. Some decode to plain text, binary data, or XML. If the decoded output isn't valid JSON, you will see a parse error — that's working as intended. The string just doesn't contain JSON.

    Technical Details

    Frequently Asked Questions

    How do I convert Base64 to JSON?

    Paste your Base64 string into the input box and click Convert. The tool decodes the Base64 text and parses the result as JSON. If it's valid, you'll see formatted JSON output you can copy or download.

    What is Base64-encoded JSON used for?

    APIs encode JSON in Base64 when sending it through channels that don't handle special characters well — think email headers, URL parameters, or message queue payloads. JWT tokens also store their claims as Base64-encoded JSON. It is a way to make structured data safe for text-only transport.

    Can I decode a JWT token with this tool?

    Partially. A JWT has three Base64 sections separated by dots. Copy just the middle section (the payload) and paste it here. The header section works too. But don't paste the entire token — that won't decode properly since the dots aren't part of valid Base64.

    Is my data safe when using this converter?

    Yes. The conversion runs entirely in your browser using JavaScript. Nothing gets uploaded, no network requests are made, and the data isn't stored anywhere. Once you close or refresh the page, it's gone.

    Why am I getting an "Invalid Base64" error?

    Usually it's extra whitespace or line breaks that snuck in when you copied the string. Base64 only allows A-Z, a-z, 0-9, plus (+), slash (/), and equals (=) for padding. Strip out any newlines, spaces, or stray characters and try again.

    Share: