Pular para o conteúdo principal
Tools Star Hub

Codificador de URL

Codifique ou decodifique partes de URL no navegador com encodeURIComponent.

Carregando ferramenta…

Esta ferramenta roda no seu navegador. Dados, arquivos e valores gerados ficam neste dispositivo. Favoritos e ferramentas recentes, se você usar, guardam apenas nomes de ferramentas no armazenamento local — nunca senhas, documentos ou conteúdo de QR codes. Veja a política de privacidade.

Por enquanto, o guia detalhado desta ferramenta (como usar, exemplos e perguntas frequentes) está em inglês.

What this tool does

Percent-encode a string with encodeURIComponent, or decode a percent-encoded string. Developers putting a query value into a URL use it when spaces, ampersands, or slashes must be escaped. The result is not encrypted, and a half-finished sequence such as %E0 fails on decode.

How to use

  1. Paste the text or encoded string into the input box.
  2. Press Encode to apply encodeURIComponent, or Decode to reverse it.
  3. Copy the result, swap the boxes, or clear both.

Examples

  • A space and an ampersand

    “a b&c” encodes to a%20b%26c.

  • Unicode

    Accented letters and other scripts encode to UTF-8 percent sequences and decode back to the original text.

How it works

URL encoding (percent-encoding) represents characters that are not safe in a URL component. It is not encryption: anyone can decode the result. This tool uses the browser’s encodeURIComponent and decodeURIComponent, which encode more characters than encodeURI (including ?, &, and /).

Limitations

encodeURIComponent is the encoder, so ?, &, and / are escaped. That is stricter than encodeURI. The output is not a secret. On the way back, a half-finished sequence such as %E0 is rejected.

See the disclaimer for what these tools do not cover.

FAQ

Is the URL Encoder free?
Yes. Percent-encoding a string, or decoding one, costs nothing and does not ask for an account.
Why did decoding fail?
Incomplete sequences such as %E0%A4%A are invalid. The tool shows an error instead of crashing.
Is my text sent to a server?
No. Encoding and decoding run in your browser.
What does %20 mean in a URL?
%20 is the percent-encoded form of a space. Percent-encoding writes a character as % followed by its byte value in hexadecimal.
What is the difference between encodeURI and encodeURIComponent?
encodeURI leaves characters such as / ? & and = alone so a whole address still works. encodeURIComponent escapes them too, which is what you want for a single query value. This tool uses encodeURIComponent.