Skip to main content

URL Encoder - Percent Encode Strings Online Free

Encode special characters in strings for use in URLs, query parameters, and form data. Supports full URL encoding and component encoding.

Runs in browser - Tool input is not submitted url encode percent-encoding developer

encodeURI

Encodes a full URL, preserving :/?#[]@!$&'()*+,;=

decodeURIComponent

Decodes any percent-encoded string back to its original form.

encodeURIComponent

Encodes everything including / - Best for query parameter values.

How to percent-encode a URL or query value

URL encoding changes characters into percent-prefixed bytes so a browser can carry them inside a URL. Full-URL mode keeps structural characters such as :, /, ?, and #. Component mode encodes those delimiters too. That mode is usually right for one query parameter value.

Paste the complete address for full-URL encoding, or choose Component Encode before entering an individual value. Encoding user-supplied values helps prevent spaces, ampersands, equals signs, and non-ASCII text from breaking a link or changing parameter boundaries. To inspect an encoded value, use the URL decoder. When text must appear literally inside HTML rather than travel in a URL, use the HTML escape tool instead.

Preserve a full URL

Full-URL mode keeps structural separators while encoding spaces and characters that cannot appear literally.

Protect one value

Component mode encodes separators too, which keeps a user value from becoming another query parameter or path segment.

Represent UTF-8 text

Non-ASCII text is converted to UTF-8 bytes and each required byte is written as a percent sequence.

Characters that need deliberate URL encoding

The correct result depends on whether the character is URL structure or data inside one component.

Character Component form Interpretation
Space %20 Encode in a URL; HTML form encoding may use a plus sign
& %26 Encode inside a value so it does not start another parameter
= %3D Encode inside a value so it is not read as a key separator
+ %2B Encode when a literal plus must not be interpreted as a space
/ %2F Preserve as path structure or encode when it belongs to one value
# %23 Encode inside a value so it does not begin the URL fragment

Related developer tools

Encode binary data and text to Base64 for safe transport
Convert special characters to entities for literal HTML display
Prettify JSON payloads you receive from URL-encoded forms
Build regex patterns for validating or extracting URL parts

Understand what changes during conversion

These maintained explanations cover the behavior, limits, and decisions that the interactive result alone cannot show.