URL Encoder & Decoder for Special Characters

Encode spaces as %20, slashes as %2F, semicolons as %3B, query parameters, and Unicode/UTF-8 text instantly in your browser.

URL Encoder & Decoder for Special Characters

0
Input Length
0
Output Length
0
Chars Encoded
1.0x
Size Ratio

Common URL Encodings for Special Characters

Character Encoded Description
(space)%20Space character
!%21Exclamation mark
#%23Hash / fragment
$%24Dollar sign
&%26Ampersand
'%27Apostrophe
+%2BPlus sign
/%2FForward slash
:%3AColon
=%3DEquals sign
?%3FQuestion mark
@%40At sign

Need the full list for reserved characters and Unicode? See the URL encoding special characters table with %20, %3B, %2F, UTF-8, and FAQ examples.

Encode URL Special Characters, Spaces and Unicode

Paste any text or web address above and this tool percent-encodes or decodes it the instant you type — no upload, no signup, no waiting. Pick encodeURIComponent for query values, encodeURI for full links, or switch to decode to turn %20, %2F, and %C3%A9 back into readable text. Everything runs locally in your browser, so the data you paste stays on your machine.

Why URL Encoding Matters

URLs can only safely carry a limited set of characters from the ASCII range. When you need to include spaces, slashes, semicolons, ampersands, accented letters, emoji, or any other non-ASCII text, those characters must be percent-encoded to keep links valid across browsers, servers, CDNs, and APIs. Skip the step and you get broken links, dropped query parameters, 400 errors from API gateways, and tracking tags that silently lose data after the first & or #.

Worked Examples

Here is how the same text changes depending on the mode you choose:

  • red shoes & socksred%20shoes%20%26%20socks (encodeURIComponent — safe as a query value)
  • https://site.com/path with spacehttps://site.com/path%20with%20space (encodeURI — structure preserved)
  • café/münchencaf%C3%A9%2Fm%C3%BCnchen (UTF-8 bytes, then percent-encoded)
  • a=1&b=2 typed as one value → a%3D1%26b%3D2 so the = and & are treated as data, not delimiters

Encoding Modes Explained

  • encodeURIComponent — Encodes everything except letters, digits, and - _ . ~. Best for query parameter values.
  • encodeURI — Preserves URL-safe characters like : / ? # [ ] @ ! $ & ' ( ) * + , ; =. Best for full URLs.
  • Path Only — Encodes a URL path segment, preserving / separators.
  • Query String — Encodes for application/x-www-form-urlencoded format (spaces become +).
  • Custom — Choose exactly which characters to encode.

Features

  • Real-time encoding and decoding as you type
  • 5 encoding modes for different use cases
  • Batch processing — encode multiple URLs line by line
  • Full Unicode/UTF-8 support
  • URL validation
  • Copy to clipboard and download output
  • Dark mode and mobile-responsive design
  • 100% client-side — your data never leaves your browser

Common Use Cases

  • Building API requests — encode search terms, IDs, filters, and redirect URLs before adding them to a query string so a stray & or = can't corrupt the request. See URL encoding for API development.
  • Fixing broken links — decode a pasted URL to read what it actually contains, or re-encode a file name or path segment that includes spaces or slashes.
  • Marketing & analytics tags — encode UTM values and campaign names so commas, spaces, and ampersands survive the redirect chain.
  • Debugging double encoding — spot the tell-tale %2520 (an already-encoded %20) and decode once to recover the original value.
  • Internationalized text — turn accented and non-Latin characters into UTF-8 percent-encoding for paths and parameters. Learn more in the UTF-8 and Unicode guide.

New to the topic? Start with What is URL encoding? or compare the JavaScript functions in encodeURI vs encodeURIComponent.

URL Encoding Guides

encodeURI vs encodeURIComponent: Which One Should You Use?

A practical guide to JavaScript URL encoding functions, with examples for full URLs, path segments, query parameters, and common bugs.

application/x-www-form-urlencoded vs JSON: When to Use Each

Compare form URL encoding and JSON request bodies for APIs, forms, webhooks, OAuth, and server integrations.

How to Decode a URL: Percent-Encoding Made Simple

Learn how to decode a URL by hand and in code. Convert %20, %2F, %3D, and UTF-8 sequences back to readable text, fix double encoding, and avoid common bugs.

How to Encode URLs in JavaScript: encodeURI vs encodeURIComponent

Master URL encoding in JavaScript. Understand the difference between encodeURI(), encodeURIComponent(), decodeURI(), and decodeURIComponent() with practical examples.

RFC 3986 Percent-Encoding: Reserved and Unreserved Characters

Understand the URL standard behind percent-encoding, including reserved characters, unreserved characters, and when encoding is required.

URL Encoding for API Development: Best Practices

Master URL encoding in API development. Learn how to safely encode query parameters, handle authentication tokens, build API clients, and avoid common encoding pitfalls.

URL Encoding Special Characters Table: %20, %3B, %2F, Unicode

Find percent encodings for URL special characters fast: space %20, semicolon %3B, slash %2F, plus %2B, reserved chars, and Unicode examples.

URL Query Parameters: Encoding Rules and Examples

Learn how query parameters are structured, how to encode names and values correctly, and how to avoid broken API requests.

UTF-8 and Unicode in URL Encoding: International Characters Guide

Learn how Unicode characters and international text are handled in URLs. Understand UTF-8 byte encoding, IDN/Punycode for domain names, and multilingual best practices.

What Is URL Encoding? A Complete Guide to Percent-Encoding

Learn what URL encoding (percent-encoding) is, why it exists, and how it transforms special characters into a safe format for use in web addresses.

Frequently Asked Questions

What is URL encoding?
URL encoding (also called percent encoding) converts characters into a format that can be safely transmitted in a URL. Special characters like spaces, ampersands, and non-ASCII characters are replaced with a percent sign (%) followed by their hexadecimal value. For example, a space becomes %20.
When should I use URL encoding?
You should URL encode any data that will be included in a URL — especially query parameters, form data, file names, and any user-generated content. This prevents broken links, security vulnerabilities, and ensures your URLs work correctly across all browsers and servers.
What is the difference between encodeURI and encodeURIComponent?
encodeURI() encodes a full URI, preserving characters like :, /, ?, #, and & that have special meaning in URLs. encodeURIComponent() encodes everything including those special characters, making it ideal for encoding individual query parameter values.
How does URL decoding work?
URL decoding reverses the encoding process. It reads percent-encoded sequences (like %20 or %C3%A9) and converts them back to their original characters. Our tool automatically detects and decodes all standard percent-encoded sequences.
Does URL encoding support Unicode characters?
Yes. Unicode characters are first encoded as UTF-8 bytes, then each byte is percent-encoded. For example, the character é (U+00E9) becomes %C3%A9 in URL encoding. Our tool fully supports Unicode/UTF-8 encoding and decoding.
Is my data safe using this tool?
Encoding and decoding happen in your browser using JavaScript, so the text you enter is not uploaded for conversion. The page itself may still load normal site services such as analytics, ads, or newsletter features.
What characters need to be URL encoded?
Characters outside the unreserved set (A-Z, a-z, 0-9, -, _, ., ~) should be encoded. Reserved characters like !, #, $, &, ', (, ), *, +, ,, /, :, ;, =, ?, @, [, ] have special meaning in URLs and must be encoded when used as data rather than delimiters.