4Internet / developer utilities

HTML Entity Encoder and Decoder

Encode or decode HTML5 character entities with an inert text output and byte counts.

Local calculation · no network request

Explore your inputs

Sample values are prefilled. Review or replace them, then calculate. Input is processed by this server for this request only.

Enter the value for this calculation.

32 KiB maximum. Decoded markup is shown as text and never executed.

A practical guide

How to use HTML Entity Encoder and Decoder

Encode or decode HTML5 character entities with an inert text output and byte counts.

  1. Choose whether to encode literal characters or decode entities.
  2. Paste the text and run the conversion. Compare the input and output byte counts.
  3. Copy the literal result. Apply escaping appropriate to the eventual destination context.

Worked example

Illustrative input and expected interpretation. This example is not a live measurement.

Input

Tom & Ana (encode)

What to expect

Tom & Ana

What to watch for

  • Entity conversion is not HTML sanitization or a guarantee that content is safe in JavaScript, CSS or URLs.
  • Encoding already encoded text may double-encode it; unknown or malformed entities can remain unchanged on decoding.

Your input: submitted to this server for processing. This tool does not send it to an AI provider. Your input is processed for this request. Temporary processing files are removed afterward. Avoid pasting secrets or personal data.

References