Vai al contenuto principale
Tools Star Hub

Codificatore / decodificatore HTML

Codifica o decodifica entità HTML nel browser. L’input viene trattato come testo, non eseguito.

Caricamento dello strumento…

Questo strumento funziona nel tuo browser. Dati inseriti, file e valori generati restano su questo dispositivo. Preferiti e strumenti recenti, se li usi, salvano solo i nomi degli strumenti nella memoria locale: mai password, documenti o contenuti dei codici QR. Consulta l’informativa sulla privacy.

Per ora la guida dettagliata di questo strumento (come si usa, esempi e domande frequenti) è disponibile in inglese.

What this tool does

Escape HTML characters so they can be shown as text, or turn common entities back into characters. Use it when a tutorial or a comment needs to display a tag instead of running it. <div> becomes &lt;div&gt;, and the markup is never executed on this page.

How to use

  1. Paste HTML or encoded text into the input box.
  2. Choose HTML encode or HTML decode, then press the matching button.
  3. Copy the result, swap the two boxes, or clear both.

Examples

  • Encode a tag

    <div>Hello</div> becomes &lt;div&gt;Hello&lt;/div&gt; so it can be shown as text.

  • Ampersands and quotes

    & is encoded as &amp;, double quotes as &quot;, and apostrophes as &#39;.

How it works

HTML encoding replaces characters that have special meaning in markup. Decoding turns common named entities and numeric character references back into characters. The tool treats your input as plain text. It does not run HTML or inject it into the page.

Limitations

The encoder escapes characters so they can be shown as text. Decode recognizes common named entities and numeric references. An uncommon named entity can remain as typed. The markup is never executed.

See the disclaimer for what these tools do not cover.

FAQ

Is the HTML Encoder / Decoder free?
Yes. Escaping HTML characters, or turning entities back into characters, is free, with no signup.
Will my HTML run on this page?
No. Input is never executed and is never inserted with innerHTML.
Is my input sent to a server?
No. Encoding and decoding happen in this tab. The text is not posted to a server or saved in local storage.
What are HTML entities?
HTML entities are codes such as &lt; for < and &amp; for & that let a page show those characters as text instead of reading them as markup.
When should I encode HTML?
Encode text when you want to display code on a page, or when user input is shown inside HTML, so tags appear as text instead of running.