I tried submitting my first epub to iBooks and got this error:

ERROR ITMS-9000: "Shankle.epub: OEBPS/Text/introduction.xhtml(11): value of attribute "id" is invalid; must be an XML name without colons

Here's the code from introduction.xhtml, line 11:

<p class="pfirst"><span class="PageNumber" id="13">Page 13</span> It is the purpose of this book to record the facts about the various state names. nicknames, flowers, trees, flags, birds, songs, seals, mottoes, capitol buildings, and some of the outstanding state histories.</p>

I'm confused; there are no colons in my code. It's just id="13". My epub shows no errors in Epub-Checker. Does anyone know what this error means?

  • Please note that there are formatting tools on the top bar of the editing window that let you write down raw code without being processed, so it will be displayed correctly.
    – Sekhemty
    Commented Jun 2, 2017 at 9:19

1 Answer 1


An XML name must begin with a letter, underscore or colon (although in this case, the colon is prohibited).

See https://www.w3.org/TR/2000/REC-xml-20001006.html#sec-common-syn

  • Now I get it - I think. id="13" doesn't work because it begins with a numeral. So all I have to do is add a letter or an underscore - id="a13" or id="_13". I'll give that a try. It's weird that neither Sigil nor Epub-Checker caught that.
    – WordBear
    Commented Jun 2, 2017 at 23:05

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.