Loadingβ¦
Loadingβ¦
Encode text or any file to Base64, or decode Base64 back to text. UTF-8 and emoji safe, with URL-safe Base64, data: URIs, and downloads for decoded images and files.
Also covers: Base64 encode Β· Base64 decode Β· Text to Base64 Β· Base64 to text Β· Image to Base64 Β· Base64URL
The result appears here as you type.
Images, PDFs, fonts, anything up to 10 MB. The file is read in your browser and never uploaded.
Encode turns text into Base64; Decode turns Base64 (standard or URL-safe, with or without = padding, or a data: URI) back into text.
The result updates as you type. Tick Each line separately to encode or decode a list, one value per line.
In Encode mode, choose any file to get its Base64 or a ready-to-use data: URI. When decoded data isn't text, it's shown as hex and can be downloaded with a detected file type (PNG, PDF, ZIPβ¦).
Base64 encodes bytes, not characters, so the text must first be turned into bytes. This tool uses UTF-8, the standard for the web and APIs. Old tools that use Latin-1, or JavaScript's btoa() alone (which fails on emoji), give different or no output.
Standard Base64 uses + and /, which have special meaning in URLs and file names. The URL-safe alphabet (RFC 4648 Β§5) uses - and _ instead and usually drops the = padding. JWTs use it. The decoder accepts both automatically.
No. It's an encoding, and anyone can decode it instantly. Never use it to hide passwords or secrets.
Base64 turns every 3 bytes into 4 characters, so it's about 33% larger (plus line breaks if MIME wrapping is on). Inline small icons as data: URIs; link larger files normally.
No. Everything runs in your browser tab, and nothing you paste or open is uploaded or stored.
Data
Format, validate, and minify JSON in your browser. Paste it, upload a file, or load it from a URL. Errors show the exact line and column.
C# / .NET
Paste JSON and get C# model classes or records, ready for System.Text.Json or Newtonsoft.Json. Nested objects, arrays, nullable types, dates, and GUIDs are inferred for you.
SQL
Format and beautify SQL queries for SQL Server (T-SQL), PostgreSQL, MySQL, Oracle, and more. Set the indentation, keyword case, and layout, and get the exact line of any syntax error.
Data
Format, validate, and minify XML (config files, .csproj, SOAP, RSS) in your browser. Entities, CDATA, and mixed content are kept exactly as written, and errors show the line and column.
Data
Format and validate YAML (docker-compose, Kubernetes, GitHub Actions) without losing comments, or convert YAML to JSON. Errors show the exact line and column.
Web
Beautify HTML pages and fragments without changing how they render. Inline spacing, <pre>, and scripts stay intact, and embedded CSS and JavaScript can be formatted too.