# EPUBCheck PKG-001: EPUB version mismatch, how to fix it

Source: https://epubcc.com/epubcheck/pkg-001/ (updated 2026-11-04)

EPUBCheck PKG-001 is a warning message: “Validating the EPUB against version … but detected version ….” EPUBCheck was told to validate one EPUB version but the package document declares another. The version comes from the version attribute of the package element, and EPUBCheck reports the mismatch as a warning before it applies the rules of the version you asked for.

- Official message (EPUBCheck 5.4.0): Validating the EPUB against version %1$s but detected version %2$s.
- Default severity: Warning

## Typical causes

- EPUBCheck was run with -v 2.0 or -v 3.0 and the file's package element has a different version attribute.
- A build script or validation service that always passes the same -v option, whatever the book is.
- A book half-converted from EPUB 2 to EPUB 3 whose version attribute was not updated.

## How to fix it

1. Run EPUBCheck without -v on a packaged .epub file: it reads the version from the package document.
2. If the version attribute itself is wrong, set it to the version the content really follows: version="3.0" for EPUB 3.
3. Validate again and fix the messages for the right version.

## When it's not this

If EPUBCheck says it is validating against 2.0 with the default profile, that is the informative PKG-023, not a mismatch.

## Sources

- EPUB 3.3, §5.4 The package element: https://www.w3.org/TR/epub-33/#sec-package-elem (read 2026-11-04)
- EPUBCheck wiki: Running EPUBCheck (command-line options): https://github.com/w3c/epubcheck/wiki/Running (read 2026-11-04)

Message text and severity: EPUBCheck (W3C, BSD-3-Clause). Explanation: EpubCC.
