# What is XHTML in EPUB?

Source: https://epublab.com/glossary/xhtml/ (updated 2026-11-03)

EPUB content documents are XHTML: HTML written with XML syntax, so every tag must be closed, attributes quoted and the file well-formed. EPUB 3 uses the XHTML syntax of HTML5; EPUB 2 used XHTML 1.1.

## Why it matters when you convert a PDF to EPUB

The text a converter extracts from a PDF must be escaped and nested correctly, or the whole chapter fails to parse; one stray "&" or an unclosed tag is enough. Parsing errors appear in EPUBCheck as RSC-005 (schema errors) or RSC-016 (fatal XML errors).
