HTML Encoder
Safely encode and decode HTML entities for web content
Input
Output
HTML Entity Reference
Character | Entity Name | Entity Number | Description |
---|---|---|---|
& | & | & | Ampersand |
< | < | < | Less than |
> | > | > | Greater than |
" | " | " | Double quote |
' | ' | ' | Single quote |
Features
Bidirectional Conversion
Encode to HTML entities and decode back to original text
Real-time Processing
Optional real-time encoding as you type
Complete Entity Support
Handles named and numeric entities
Content Swap
Easily swap input and output content
Usage Examples
HTML Content Display
Encode HTML to safely display it as text:
<div class="example">Hello
<strong>World</strong>!</div>
Attribute Values
Encode quotes for HTML attributes:
<input value="Hello "World"!" />
Security Prevention
Prevent XSS attacks by encoding user input:
<script>alert('XSS');</script>