The 8 most common JSON errors and how to fix them
Trailing commas, single quotes, comments, malformed numbers… what each error means and how to fix it.
Convert UTF-8 text and files to and from Base64.
Runs in your browser
Output
wqFIb2xhLCBtdW5kbyEg8J+Riw==
28 characters
Base64 represents binary data using only 64 text characters so it can be embedded in JSON, emails, URLs or CSS. This tool encodes and decodes text as proper UTF-8, so accents and emoji don't get mangled.
It can also convert files up to 5 MB to Base64 and supports the URL-safe variant (base64url).
“Año” encodes to QcOxbw== (UTF-8). Many older tools break on non-ASCII characters.
Convert a small icon to Base64 and use it as a data URL in your stylesheet.
It replaces + and / with - and _ and drops the = padding so the result can go in a URL or file name without escaping. JWTs use it, for example.
Because the data is binary (an image, a PDF…) rather than text. You can download it as a file.
No. Encoding uses your browser's TextEncoder, TextDecoder and btoa APIs.
Trailing commas, single quotes, comments, malformed numbers… what each error means and how to fix it.