Unformat.online
More tools
Clean Text
Strip smart quotes, zero-width characters, non-breaking spaces, and invisible Unicode from any pasted text.
Markdown Viewer
Live split-view editor and renderer — edit on the left, preview on the right.
Text Diff Checker
Compare two texts, JSON payloads, or config files and see exactly what changed, line by line.
Log File Viewer
Open multi-gigabyte log files instantly — chunked indexing and virtual scrolling handle 10GB+ files without freezing your tab.
FileSQL
Drop a CSV or JSON file and query it with SQL instantly — no upload, no server.
Format SQL
Format SQL for MySQL, PostgreSQL, BigQuery, T-SQL, and more — uppercase keywords, proper indentation.
Schema Visualizer
Paste CREATE TABLE statements and get an ER diagram instantly — tables, columns, keys, and foreign-key relationships.
Format JSON
Prettify or minify JSON. Auto-fixes single quotes, trailing commas, and unquoted keys.
Format YAML
Format and validate YAML. Catches indentation errors in Kubernetes, Docker Compose, and GitHub Actions files.
Format XML
Indent and pretty-print XML. Works with SOAP, RSS, Maven POM, Android manifests, and SVG.
JWT Debugger
Decode JWTs instantly — view all claims, check expiry, and see the algorithm. Token never leaves your browser.
Shredder
Remove EXIF, GPS, and author metadata from images and PDFs. Redact secrets from text and log files.
SSL Certificate Checker
Check any domain's SSL/TLS certificate — expiry, issuer, and Subject Alternative Names.
PDF Tools
Merge, split, rotate, or sign PDFs, fill in forms, and add text — entirely in your browser, nothing uploaded.
CronScope
Paste a cron schedule and see every run on a 12-month calendar. Never misread a cron expression again.
Regex Tester
Test regex patterns against sample text with live-highlighted matches, or pick from a library of ready-made patterns — no regex knowledge required.
Base64
Encode text or files to Base64, or decode Base64 strings and preview images inline.
URL Encode / Decode
Encode URLs or decode percent-encoded strings like %20, %3D, %26 — instantly.
UUID Generator
Bulk-generate cryptographically random v4 UUIDs using crypto.randomUUID(). Copy one or all at once.

URL Encode / Decode

Fix broken query strings, decode percent-encoded characters like %20, %3D, and %26, or encode plain text for safe use in URLs. Real-time output, 100% client-side.

Plain text
URL-encoded output
Try:

100% Private

All encoding and decoding happens in your browser using JavaScript's built-in encodeURIComponent and decodeURIComponent functions. Your URLs and query strings are never sent to any server.

Real-Time Output

Output updates instantly as you type — no button to click. Paste a query string and see the decoded values immediately, or type plain text and watch it get percent-encoded character by character.

Error Detection

If you paste a malformed percent-encoded string (e.g. a lone % with no following hex digits), the decoder flags the exact problem so you can fix it without guessing.

How to URL Encode a String

  1. Select the Encode → tab.
  2. Paste or type the text you want to encode in the left box.
  3. The URL-encoded output appears instantly in the right box.
  4. Click Copy to copy the result to your clipboard.

How to URL Decode a String

  1. Select the ← Decode tab.
  2. Paste your percent-encoded string (e.g. hello%20world%21) in the left box.
  3. The decoded, human-readable text appears on the right.
  4. If the input contains invalid escape sequences, an error message explains the problem.

What Is URL Encoding?

URL encoding — formally called percent encoding and defined in RFC 3986 — converts characters that cannot safely appear in a URL into an ASCII-compatible representation. Each character that needs encoding becomes a percent sign % followed by two hexadecimal digits: the UTF-8 byte value of the character.

For example, a space character (UTF-8 byte 0x20) becomes %20. An equals sign (0x3D) becomes %3D. An ampersand (0x26) becomes %26.

CharacterEncodedWhy it matters
Space%20Spaces are illegal in URLs
=%3DSeparates query parameter name from value
&%26Separates multiple query parameters
+%2BAmbiguous — sometimes decoded as a space
/%2FPath separator — must be encoded in values
?%3FStarts the query string — must be encoded in values
#%23Fragment identifier — must be encoded in values
@%40Used in userinfo and email addresses
:%3APort and scheme separator
%%25Escape character itself — must be encoded literally

encodeURIComponent vs encodeURI

JavaScript has two built-in functions for URL encoding, and choosing the wrong one is a common source of bugs:

  • encodeURIComponent — encodes everything except letters, digits, and - _ . ! ~ * ' ( ). Use this for individual query parameter values. This is what this tool uses.
  • encodeURI — leaves URL structural characters intact (: / ? # [ ] @ and others) so a complete URL is not broken. Use this only when you want to encode an entire URL that is already well-formed.

Rule of thumb: if you are encoding a value to put inside a query string (like a search term or a redirect URL), always use encodeURIComponent. If you are encoding an entire URL for use as an attribute value in HTML, use encodeURI first and then encode the result only if needed.

Frequently Asked Questions

What is URL encoding?

URL encoding replaces unsafe characters in a URL with a percent sign (%) followed by two hexadecimal digits. For example, a space becomes %20. This makes it possible to include any character in a URL without breaking the URL structure.

Why does %20 appear in my URLs?

%20 is the URL-encoded form of a space character. It appears when a URL contains a space that was encoded by a browser, form handler, or API. Paste the URL into the Decode tab to read it in plain text.

What is the difference between %20 and + for spaces?

Both represent a space, but in different contexts. %20 is the RFC 3986 standard and is safe anywhere in a URL. The + sign for spaces comes from the older application/x-www-form-urlencoded format used by HTML forms. Stick with %20 unless you are specifically working with HTML form data.

Is my data sent to a server?

No. Encoding and decoding run entirely in your browser using JavaScript's built-in encodeURIComponent() and decodeURIComponent() functions. No network requests are made — you can verify this by opening DevTools and checking the Network tab.

Why do I get an error when decoding?

A decode error means the input contains an invalid percent-escape sequence — for example, a lone % not followed by two hex digits (like %GG or a truncated %2). Fix the broken sequence or re-copy the encoded string from its source.