About This HTML Issue
An attribute value closed with two single quotes, or an apostrophe written as '' inside a single-quoted value, leaves a stray ' where the parser expects the next attribute name.
In a single-quoted value such as alt='Spring concert', the next ' after the opening one ends the value. After that the parser expects a space and another attribute, or the end of the tag. An extra quote right after the closing one, as in alt='Spring concert'', can't start an attribute name, so the validator reports it, usually next to "No space between attributes". Browsers treat the stray quote as the name of a new, unknown attribute, and the validator flags that attribute as not allowed on the element.
The doubled apostrophe does more damage. SQL string literals escape an apostrophe by writing it twice, and some code that builds HTML copies that convention, but HTML has no such escape. In alt='Children''s choir', the value ends after Children, and 's and choir' become separate junk attributes. Screen readers read the image's text alternative as just "Children".
The "probable cause" in the message is misleading for single quotes. A missing =, as in title'Contact', produces a different message about a quote in an attribute name. This one appears when the quote sits where a new attribute should start: right after a closing quote, or after a space that follows a complete attribute, as in class='note' 'intro'.
Delete the extra quote. When the value itself contains an apostrophe, wrap it in double quotes (alt="Children's choir") or write the apostrophe as ' or '. If a CMS or template prints the attribute, fix the escaping there so every page gets the correct output.
Invalid example
<img src="concert.jpg" alt='Spring concert'' width="300" height="200">
<img src="choir.jpg" alt='Children''s choir' width="300" height="200">
Valid example
<img src="concert.jpg" alt="Spring concert" width="300" height="200">
<img src="choir.jpg" alt="Children's choir" width="300" height="200">
Find issues like this automatically
Rocket Validator scans thousands of pages in seconds, detecting HTML issues across your entire site.