Difference Between Single and Double Quotes in HTML

Double quotes around attribute values are the most common in HTML, but single quotes can also be used.

In some situations, when the attribute value itself contains double quotes, it is necessary to use single quotes:

<p title='John "ShotGun" Nelson'>


<p title='John "ShotGun" Nelson'>

Leave a Comment