RSC-012: Fragment Identifier Is Not Defined — Plain-English Fix
You got rejected with "RSC-012: Fragment identifier is not defined." Here's what it means, why it happens, and how to fix it.
You submit your EPUB to Apple Books. The rejection email lands in your inbox:
Error message:
RSC-012: Fragment identifier is not defined
You have no idea what that means. You search Google. You find 10 different "solutions." None of them work.
Here's what's actually happening: Your EPUB has a link that points to something that doesn't exist.
Got RSC-012 and want it fixed?
I validate and fix EPUBs before delivery. Pricing starts at $49. Send your file here.
What RSC-012 Actually Means
In plain English: "Your EPUB has a link that points to an ID that doesn't exist."
Where you see it: Apple Books, Kobo, IngramSpark, or any platform that uses EPUBCheck validation.
Why Amazon ignores it: Amazon's validator doesn't strictly enforce this. Amazon accepts files with broken links and silently fixes them.
Why everyone else rejects it: Apple Books, Kobo, and IngramSpark use EPUBCheck, which enforces the W3C EPUB 3.0 standard to the letter. No broken links allowed.
What Causes RSC-012
Every link in your EPUB needs a target. If the link points somewhere that doesn't exist, you get RSC-012.
Common causes:
- Broken table of contents: Your TOC links to Chapter 5, but the chapter heading in the content file has a different ID
- Endnote links: You link to a footnote, but the anchor doesn't exist
- Cross-references: You reference "See page X" but the target ID is missing
- InDesign export: InDesign's "Page Navigation" export feature creates links to pages that don't exist in EPUB
Real Example
Your table of contents has this link:
<a href="chapter01.xhtml#ch1-intro">Introduction</a>
But in the actual chapter file, the heading is:
<h1 id="ch1-heading">Introduction</h1>
The problem: The TOC links to #ch1-intro, but the ID in the file is #ch1-heading.
Result = RSC-012 error.
Why This Breaks Publishing
When a reader tries to tap the Table of Contents on Apple Books or Kobo, the link goes nowhere. The reader gets a broken navigation experience.
That's why Apple, Kobo, and IngramSpark reject it immediately. They don't want broken books in their stores.
Amazon is more forgiving. Amazon fixes broken links on its end. That's why the same EPUB passes KDP but fails everywhere else.
How to Fix RSC-012 (DIY Path)
Fixing this requires unzipping your EPUB and editing the files. It's technical, but doable if you're patient.
Step 1: Get the error details
- Run your EPUB through EPUBCheck (free online at
validator.w3.org/epub-validator) - EPUBCheck will tell you EXACTLY which file has the broken link and what ID is missing
Step 2: Unzip your EPUB
- Rename
filename.epubtofilename.zip - Unzip the file
- You'll see folders like
OEBPS/,META-INF/, etc.
Step 3: Find and fix the broken link
- Open the problem file in a text editor (the .xhtml file EPUBCheck flagged)
- Find the broken link:
<a href="file.xhtml#missing-id"> - Check the target file to see what the actual ID is
- Update the link to point to the correct ID
Step 4: Re-zip the EPUB
- Zip the unzipped folder back into an .epub file
- Critical: Make sure mimetype is the FIRST file in the zip and is UNCOMPRESSED
- This is where most people mess up
Step 5: Validate again
- Run the new EPUB through EPUBCheck
- If you still get RSC-012, repeat steps 3-5
Special Case: InDesign's Page Navigation
If you exported your EPUB from InDesign, there's a specific checkbox causing RSC-012: "Page Navigation" under the EPUB export options.
This feature creates links to pages, but pages don't exist in reflowable EPUB format. The result: orphaned links pointing nowhere.
The fix: Uncheck "Page Navigation" when exporting EPUB from InDesign and re-export.
Why Most People Just Hire Someone
RSC-012 is fixable, but it requires:
- Understanding EPUB structure (XML, manifest, IDs)
- Using a text editor without breaking the file
- Re-zipping with specific flags (mimetype first, uncompressed)
- Validating multiple times until it passes
For most authors, this is 2-4 hours of frustrating debugging.
Alternatively: You hire someone who builds the file correctly from the start, with all links validated before delivery.
Same outcome (an EPUB that passes all platforms). One path takes minutes. The other takes hours.
Real-World RSC-012 Stories
Story 1: The Table of Contents Mismatch
An author formatted her manuscript in Word with a manually created table of contents. She clicked each chapter title to create a link, but Word's behind-the-scenes ID generation didn't match what she expected. Her TOC said "Chapter 5" with link #chapter5, but Word actually created the chapter heading with ID #c5. Mismatch = RSC-012.
Story 2: The InDesign Page Navigation Trap
A designer exported an EPUB from InDesign with "Page Navigation" enabled (a default option many designers don't notice). This created navigation markers for pages 1, 2, 3, etc. But in reflowable EPUB, pages don't exist—they change based on screen size and font size. All those page markers became orphaned links = RSC-012 errors across the entire book.
Story 3: The Footnote Gone Missing
An author had a footnote reference in Chapter 3 that linked to endnote #15. But when she restructured her book, she deleted some endnotes and renumbered them. The reference still pointed to #15, but #15 no longer existed. Small mistake, big validation error.
Story 4: The Duplicate Chapter ID
An author built her EPUB with Calibre. Two chapters accidentally got the same ID ("chapter" and "chapter" instead of "chapter1" and "chapter2"). The TOC linked to "chapter" — ambiguous. EPUB validators hate ambiguity. RSC-012.
The common thread: These are all small mistakes that don't break the reading experience on Amazon (Amazon fixes them), but they break strict validation on Apple/Kobo/IngramSpark.
Why the DIY Debugging Path Is So Frustrating
When you hit RSC-012, the typical DIY workflow looks like this:
- Upload to Apple Books — get rejected with "RSC-012"
- Panic. "What does RSC-012 even mean?"
- Google it — find 47 conflicting explanations
- Download EPUBCheck — learn to use a command-line tool (not trivial for non-tech authors)
- Run EPUBCheck — get an error message like: "RSC-012 at file chapter03.xhtml, line 42: reference to undefined id 'section-A'"
- Unzip your EPUB — navigate a folder structure you've never seen before
- Open chapter03.xhtml in a text editor — see a wall of XML/HTML code
- Search for "section-A" — can't find it anywhere
- Search for the link that references section-A — find something like
<a href="chapter02.xhtml#section-A"> - Go to chapter02.xhtml — search for "section-A" ID. Not there.
- Realize the ID is in a different file — spend 30 minutes searching
- Finally fix the link — update it to point to the right file and ID
- Re-zip the EPUB — struggling with ZIP commands to ensure mimetype is first/uncompressed
- Validate again — find 2 more RSC-012 errors you didn't know about
- Repeat steps 7-13 two more times
- Finally get zero errors — 4 hours later
That workflow would take an expert ~30 minutes. For most authors, it takes 2-4 hours with dead ends and frustration.
Why Professionals Don't Hit This Problem
When I build an EPUB, RSC-012 never happens because:
- I build the table of contents programmatically — the tool creates links automatically based on heading IDs that already exist in the file. No manual linking, no mismatches.
- Every heading gets a unique, consistent ID — I name them systematically (ch01, ch02, etc.) and don't change them after creation
- I test internal links during production — before the final EPUB is delivered, I verify every link actually points to something that exists
- I validate with EPUBCheck before sending — you get a file with zero errors. No surprises on upload.
The result: RSC-012 never appears because it never existed in the first place.
How to Prevent RSC-012
If you're building your own EPUB, follow these rules religiously:
- Use heading styles consistently throughout your manuscript. Every chapter should have a proper Heading 1 or Heading 2 style applied. Don't manually format headings—use styles. Formatting tools generate IDs from these styles.
- Never manually create your table of contents. Use your tool's built-in TOC generator (Calibre, Scrivener, Word, Google Docs all have these). Automatic TOCs pull from your heading styles and create matching links automatically.
- Don't change heading IDs after you've created them. Once your EPUB is built, don't go back and rename chapters or restructure sections. That breaks links.
- If you use InDesign, UNCHECK "Page Navigation" in the EPUB export options. This feature creates page markers that don't exist in reflowable EPUB.
- Validate with EPUBCheck BEFORE uploading to any platform besides Amazon. Catch RSC-012 and other errors before rejection.
- Test your TOC links in Kindle Previewer or a real device. Tap each chapter link and make sure it jumps to the right place. If a link doesn't work on your device, it's broken in the file.
The Time Investment Calculation
DIY RSC-012 Debugging: 2-4 hours (or longer if you're stuck)
Professional Formatting: Built-in validation, zero RSC-012 errors, ready to upload
If you value your time at $25/hour, DIY debugging costs $50-100+ in time. Professional formatting costs $49-150 upfront but eliminates the entire debugging workflow.
The Bottom Line
RSC-012 is annoying, but it's not a mystery. A link is broken. Find it. Fix it. Validate. Done.
The problem is that "finding it" is the hard part. For non-technical authors, debugging EPUB XML takes hours.
If you're stuck after 30 minutes of troubleshooting: Stop. It's faster and cheaper to hire a professional than to spend another 3 hours debugging XML. You'll get a file that passes not just Apple Books, but every platform that uses strict validation.
Tired of validation errors blocking your launch?
I validate every EPUB before delivery and fix any errors. You get a file that passes Apple Books, Kobo, IngramSpark, and every major platform—no guessing, no debugging.