Match the report title.
Look for "RSC_012 fragment identifier is not defined" or the closest title listed above. If the platform wording is different, keep the original EPUBCheck, KDP, or Kindle Previewer message before choosing a fix.
Use this when the target file exists but the link destination after # is missing. Check the XHTML file and anchor id before you edit TOC, footnotes, or chapter links.
The scan shows affected paths and repair decisions. It does not show manuscript text.
Not sure this kind of EPUB should be scanned here? Check unsupported or review-first EPUB cases.
Scan report titles
Read the scan report
Use the report label, affected file, and repair decision together. A matching title alone is not enough if the file path or EPUB structure points to a different problem.
Look for "RSC_012 fragment identifier is not defined" or the closest title listed above. If the platform wording is different, keep the original EPUBCheck, KDP, or Kindle Previewer message before choosing a fix.
Use the report's Affected area, Source file, Target file, or Problem type rows before editing content.opf, nav.xhtml, toc.ncx, XHTML, CSS, or image paths.
Repairable means EPUB Fixer found one clear structural change. Needs review or Not supported means use the named file, source project, or platform step instead of guessing.
Repair summary
Copy the report summary instead of rebuilding the fix from memory. A useful repair note keeps the source file, target file or field, original error, repair decision, and next step together.
1. Example report output
The useful detail is not just the code. It is the file before the # symbol, the missing fragment after it, and whether the link is navigation, a footnote, or an ordinary section jump.
EPUBCheck message
ERROR(RSC-012): OEBPS/nav.xhtml(18,32): Fragment identifier is not defined.
KDP / Previewer wording
A table of contents, footnote, or internal link points to a missing location.
EPUB Fixer report
Source link OEBPS/nav.xhtml, target file OEBPS/Text/chapter2.xhtml, missing fragment #note-4.
Do this next
Open the target XHTML file and confirm the intended id before adding or renaming an anchor.
Do not do this
Do not add #note-4 to the top of the chapter unless that is where the reader should land.
A renamed heading id can be safe to align. Footnotes and backlinks need context because the wrong anchor can send readers to the wrong note.
2. Next step
RSC_012 is usually an anchor problem. Split the target into file path and fragment before deciding whether to scan, inspect manually, or fix it in the source tool or EPUB editor.
Upload scan
RSC_012 means the file before # exists, but the id after # is missing inside that target file. The report should show the source link, the target XHTML file, and whether the missing fragment belongs to a TOC entry, chapter link, footnote, endnote, or backlink.
Manual check
For footnotes, backlinks, or repeated headings, the correct fix depends on where the reader should land. Open the target XHTML file, compare the nearby text around the missing id, and only add or rename an id when the exact reading location is clear.
Repair summary
Some export tools rename heading, note, or body ids during export. If the report shows the old fragment is gone and no single replacement is obvious, send the source file, target file, missing fragment, and nearby heading or note text so the source project can be fixed cleanly.
3. Concrete path example
The file can exist while the anchor after the # is still missing.
Message: ERROR(RSC-012): OEBPS/nav.xhtml points to Text/chapter2.xhtml#section-5 Report shows: file exists, missing id section-5 Possible id: sec-5 Fix: use sec-5 only if it is the same reading location
Only use sec-5 if it is the intended heading. Do not point the link to a different section just because the name looks similar.
Quick decision
The file before the # and the fragment after it must both be checked. The same missing id can be harmless in a section link and risky in a footnote loop.
Scan first
Scan the EPUB to locate the source link and target XHTML file, then decide whether the missing fragment is a heading, TOC target, footnote, or backlink.
Safe fix
A renamed heading id or moved body id can be repaired when the target file contains one obvious replacement and the reader will land at the same section. Update the link to that existing id instead of creating a new anchor in the wrong place.
Manual review
Footnotes and repeated section titles are easy to mis-target. Do not create a new id unless you know exactly where the reader should land.
Start here
RSC_012 is easy to misread as a missing chapter. Usually the XHTML file exists; the problem is the anchor after the #. Check those two parts separately before changing nav or footnote links.
The target XHTML file exists, but the exact anchor inside that file does not. This is different from a missing file error: the path before the # resolves, while the fragment after the # points to an id that is absent, renamed, duplicated, or located in a different file.
EPUB Fixer can repair a fragment only when there is one clear target, such as a moved body id, an obvious heading id mismatch, or a unique nearby anchor in the same XHTML file. A safe repair should keep the link in the same reading context and pass EPUBCheck again after the change.
Split the broken link into two parts: the file path before # and the anchor name after #.
Footnotes, endnotes, repeated headings, and duplicated section titles often require manual review because choosing the wrong anchor can send readers to the wrong note, chapter section, or backlink. Do not create a new anchor if you cannot prove where the reader should land.
Common situations
RSC_012 always points after a # symbol, but the source of that link determines the risk.
The chapter file exists, but the heading id after # changed during export or editing, so the TOC opens a location that no longer exists.
Update the TOC link only when the target heading is unique in that chapter and the reading order still matches.
The note may have been renumbered, moved to an endnotes file, or split into another chapter, so adding the old id in the wrong place can send readers to the wrong note.
Check both the forward note link and the return backlink before changing ids.
The note itself can exist while the return target no longer exists in the chapter.
Do not point every backlink to the chapter top; choose the original reading location or review manually.
Export tools can generate similar ids for repeated headings such as Introduction, Notes, or Chapter Summary.
Stop for manual review unless one target is clearly tied to the source link.
Some exports leave links such as chapter.xhtml#bodymatter after the chapter body id was removed or renamed.
Check the target file for the current body or heading id. Do not replace it with the first id you find.
RSC_012: Fragment identifier is not defined.
KDP, Kindle Previewer, or EPUBCheck finds a link such as chapter.xhtml#note-4, chapter2.xhtml#section-5, or nav.xhtml#toc, but the target XHTML file has no matching id attribute for the fragment after the # symbol.
What it means
The target XHTML file exists, but the exact anchor inside that file does not. This is different from a missing file error: the path before the # resolves, while the fragment after the # points to an id that is absent, renamed, duplicated, or located in a different file.
This often happens after headings, footnotes, endnotes, or TOC entries are edited and the old id remains in a nav file, NCX file, chapter link, or footnote backlink. Export tools can also regenerate heading ids while preserving older links from a previous EPUB build.
Before you edit
A safe repair keeps the reader in the same place the original link intended. That is why footnotes, endnotes, repeated headings, and backlinks need more caution than ordinary section anchors.
Why KDP checks it
EPUBCheck checks EPUB 2 and EPUB 3 files against the official rules and reports package, markup, link, and file-reference problems.
The OPF file is the EPUB's map: metadata, file list, reading order, and navigation wiring. KDP and EPUBCheck use it to decide whether the book package is coherent.
Can this be fixed safely?
EPUB Fixer can repair a fragment only when there is one clear target, such as a moved body id, an obvious heading id mismatch, or a unique nearby anchor in the same XHTML file. A safe repair should keep the link in the same reading context and pass EPUBCheck again after the change.
Footnotes, endnotes, repeated headings, and duplicated section titles often require manual review because choosing the wrong anchor can send readers to the wrong note, chapter section, or backlink. Do not create a new anchor if you cannot prove where the reader should land.
Before: nav.xhtml links to chapter2.xhtml#section-5, but chapter2.xhtml contains id="sec-5" on the intended heading. After: the link is updated only if that is the single safe match. Before: a footnote backlink points to #fnref12 but the chapter has several note references; that should stop for manual review.
Ready to retry?
The scan helps show whether the broken fragment is in a TOC entry, a footnote backlink, an endnote, or an ordinary chapter link, which changes the safe next step.
Upload EPUB to scanFAQ
It means the EPUB link points to a file that exists, but the anchor after the # symbol does not exist inside that file. This often affects table of contents links, footnotes, endnotes, or heading links.
Compare the link target with the id values inside the target XHTML file. Start with the file path before the # symbol, then check the fragment against headings, footnotes, and backlinks. A safe fix requires one clear matching anchor; otherwise the link may send readers to the wrong section.
Editing tools can rename headings, footnotes, or section ids while old links remain in the nav, NCX, or chapter files. The file path still works, but the specific fragment target is gone.
Only when there is a single obvious replacement anchor, such as a moved body id or a simple heading id mismatch. Footnotes and duplicated headings usually need manual review.
A TOC or nav file can point to a chapter file and a specific heading id. If the chapter file still exists but the heading id changed during export, the TOC entry becomes a broken fragment even though the chapter itself is present.
Only when you know the exact reading location the link should target. Adding a new id just to satisfy the validator can create a valid but misleading link, especially for footnotes, endnotes, and repeated headings.
Footnotes often have forward links and backlinks. If the wrong id is chosen, the EPUB may validate while readers jump to the wrong note or cannot return to the text.