Definition:
HTML Entities convert characters into special codes called entities so that the browser can correctly recognize and display special symbols on a webpage without breaking the structure.
Syntax:
&entity_name;
where,
entity_name = special character
Advantages of HTML Entities:
- It helps the browser identify special characters correctly without confusion.
- It helps reduce browser errors caused by special symbols.
- It represents special symbols in a safe and readable format.
- It helps maintain the webpage structure when special characters are displayed.
Entity Types:
There are two types of HTML entities, which are listed as follows:
