inyourbrowser.com

URL Encoder / Decoder

URL encoder and decoder is a data tool that percent-encodes special characters with encodeURIComponent and decodes percent-encoded text back, with an option to treat + as a space. A dedicated page parses query strings into readable key-value pairs. The tool runs in your browser.

Input
Output

URL TOOLS

Encodes special characters using percent-encoding (encodeURIComponent). Safe for use in query string values.

Runs entirely in your browser

How to URL-encode or decode text

  1. Choose Encode or Decode.
  2. Type or paste the text to encode or decode into the input area.
  3. The result appears immediately.
  4. Click "Copy" to copy the result to your clipboard.

Common uses

  • Encoding query string parameters that contain spaces or special characters, use Base64 encoding when you need to embed binary data in the URL instead
  • Decoding percent-encoded URLs from server logs or redirects to make them readable
  • Building URLs programmatically and ensuring special characters are properly escaped, also useful with HTML entity encoding for safe output in web pages

Technical specification

  • Algorithm or formula: Percent-encoding per RFC 3986. Encode uses encodeURIComponent, which also encodes delimiters such as / ? & =, so it suits single values rather than whole URLs. Decode uses decodeURIComponent, optionally turning + into a space first.
  • Browser API or library: Native encodeURIComponent, decodeURIComponent, and URLSearchParams for query-string parsing.
  • Input limits: No hard cap; tested at 1 MB inputs without delay.
  • Output: Encoded or decoded string in the output pane. Query-string mode returns a parsed key-value table.
  • Known limitations: Malformed percent escapes during decode throw a URIError, surfaced as an inline error message. Encoding does not handle internationalised domain names (IDN/Punycode); use the IDN ToASCII algorithm beforehand if needed.

Frequently asked questions

What is URL encoding?
URL encoding (percent encoding) converts characters not safe in URLs, like spaces, ampersands, and accented letters, into a percent sign followed by two hex digits. For example, a space becomes %20.
When should I encode the full URL vs just the query value?
Encode individual query parameter values, not the full URL. Encoding the entire URL will break the scheme and path structure.
Is my data sent to a server?
Encoding and decoding happen entirely in your browser using JavaScript. Our servers are not involved at any point.
What characters are safe in URLs without encoding?
Letters (A-Z, a-z), digits (0-9), and the characters hyphen, underscore, period, and tilde are unreserved and never need encoding.

Related tools

Base64
Encode text or files to Base64, decode Base64, or convert images to data URIs.
HTML entity encoder
Encode special characters to HTML entities and decode them back. Instant, in your browser.
Slug generator
Convert any text into a URL-safe slug. Handles diacritics, special characters, and custom separators.
QR code generator
Generate QR codes for URLs, plain text, or Wi-Fi credentials. Download as PNG or copy as SVG. Runs in your browser.

Reviewed and tested September 30, 2026.