EPUB Formatting: Ghost Spacing (Extra Blank Lines in E-Reader Preview)
What causes this error?
Ghost spacing is a common formatting problem, not a strict validation error: blank-looking lines appear between paragraphs or chapters in e-reader previews that weren't in your original manuscript. The two most common causes are (1) empty <p></p> or <p> </p> tags used as visual spacers during Word-to-EPUB conversion, which render as full paragraph-height gaps on e-readers, and (2) CSS margin conflicts where both the top margin of one paragraph and the bottom margin of the previous one stack, doubling the visible gap. Some conversion tools also insert zero-width space characters (U+200B) that are invisible in editors but create rendering artifacts in certain readers.
How to fix it
- Open your EPUB HTML chapter files and search for empty
<p>tags:<p></p>,<p> </p>, or<p> </p>— delete them and use CSS margin instead of empty tags for spacing. - Check your stylesheet for CSS like
p { margin-top: 1em; margin-bottom: 1em; }— this doubles gaps between paragraphs. Use either top OR bottom margin, not both:p { margin: 0; text-indent: 1.5em; }is the standard for ebook body text. - Search for zero-width space characters (Unicode U+200B) using find-and-replace in Sigil or Calibre — replace with nothing.
- After changes, re-open in Kindle Previewer and Kobo desktop app to verify spacing looks correct on both.
- Re-validate your EPUB to confirm no new errors were introduced during editing.
Common questions
Why does spacing look fine in my Word document but wrong in the EPUB?
Word uses page-based layout where blank lines have a fixed height. EPUB uses CSS on a reflowing canvas — a blank paragraph tag renders differently on each e-reader based on its default line height and font size. Something that looked like a small gap in Word can become a full blank screen-height gap on Kindle.
Is ghost spacing the same as chapter break spacing?
No — chapter break spacing is intentional and usually comes from a CSS page-break rule or a large top margin on the chapter heading. Ghost spacing is unintentional: it appears within the body text or at the start/end of chapters where you didn't add space deliberately.
Check your EPUB before uploading
The free EPUB Validator catches structure, metadata, and navigation errors — no signup, no Java, runs in the browser.
Validate Your EPUB Free →Building your EPUB correctly from the start prevents most of these errors before they happen. See the EPUB formatting guide for the full workflow: manuscript cleanup, TOC, front matter, EPUB 3.0 generation, and validation.
Tool comparisons: Sigil alternative for EPUB editing, Scrivener alternative for ebook production
Common formatting mistakes: Word and Scrivener export mistakes guide