./prontouso.com
ALAT DEVELOPER

Pengonversi Entitas HTML

Konversi karakter khusus seperti <, >, &, dan kutip menjadi entitas HTML (&lt;, &gt;, &amp;) atau decode entitas kembali menjadi teks asli.

Status alatBerjalan di browser Anda
Pratinjau
prontouso://dev/html-entity-encoder-decoder
LocalLive
Encoding scope
InputHTML detected
Characters31
Lines1
Entities0
ResultHTML entities
Characters57
Lines1
Entities7
Safe HTMLEscapes only the five characters that break HTML markup: & < > " '.
Full UnicodeAlso turns every other non-ASCII character — accents, emoji, symbols — into a numeric reference.
Examples

Cara kerja

  1. Masukkan data Anda

    Isi nilai yang diperlukan, tempel teks Anda, atau unggah file yang ingin diproses.

  2. Lihat hasil seketika

    Sebagian besar alat diperbarui secara langsung saat Anda mengetik; beberapa menggunakan satu tombol tindakan.

  3. Gunakan hasil Anda

    Salin, unduh, atau bagikan hasil yang dihasilkan — Anda selalu memiliki kendali penuh atas data Anda.

Privasi dan pemrosesan data — Berjalan secara lokal di browser Anda. Alat ini tidak mengunggah data Anda.

Apa itu Pengonversi Entitas HTML?

Convert characters that have special meaning in HTML into safe entities, or decode entity text back to readable characters.

PAHAMI CARA KERJA ALAT

How to encode and decode HTML entities

When to encode entities

Encode entities when you need to show code as text, paste snippets into a CMS field, or prevent characters like < and & from being interpreted as markup.

How to use it

  • Paste HTML, text, or entity-encoded content into the input box.
  • Choose Encode to escape special characters.
  • Choose Decode to turn entities back into readable text.
  • Copy the output when it looks right.

Common uses

  • Showing HTML snippets inside documentation.
  • Preparing safe text for template examples.
  • Cleaning copied content that contains visible entity codes.

Encoding example

Show a tag as text

Characters that would be interpreted by HTML are replaced with entities, including ampersands, angle brackets, quotes, and apostrophes.

<button title="Tom & Ana's"> -> &lt;button title=&quot;Tom &amp; Ana&#39;s&quot;&gt;

Entity notes

Entity encoding helps display HTML-looking text as text. In production apps, still rely on the framework or template engine's escaping rules.

Pertanyaan yang Sering Diajukan (FAQ)

What characters are encoded?

The tool encodes the characters most likely to break HTML text: &, <, >, double quotes, and apostrophes.

Can it decode numeric entities?

Yes. It supports common named entities and numeric decimal or hexadecimal entities.

Does encoding sanitize unsafe HTML?

No. It escapes text for display, but it is not a complete HTML sanitizer for untrusted markup.

Which named entities are decoded?

The named map covers amp, lt, gt, quot, apos, and #39. Numeric decimal and hexadecimal entities are decoded too.