# MED_016: overlay duration sum mismatch, how to fix it

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

EPUBCheck MED_016 is a warning message: “Media Overlays total duration should be the sum of the durations of all Media Overlays documents.” The total media overlay duration in the package does not match the sum of each overlay's duration. EPUB asks for the total (media:duration without refines) to equal the sum, within one second.

- Official message (EPUBCheck 5.4.0): Media Overlays total duration should be the sum of the durations of all Media Overlays documents.
- Default severity: Warning

## Typical causes

- Narration re-recorded or trimmed without updating the durations in the package metadata.
- An overlay added or removed while the total stayed the same.

## How to fix it

1. List the media:duration meta elements that refine each SMIL item and add them up.
2. Set the media:duration without refines to that total, for example <meta property="media:duration">1:36:20</meta>.
3. If a single overlay's duration is wrong, measure it from its audio and correct that value too.
4. Rebuild the EPUB and run EPUBCheck again to confirm the message is gone.

## When it's not this

If clip times inside a SMIL file are wrong, the errors are MED-008 or MED-009.

## Sources

- EPUB 3.3, §9.3.5.2 Overlays package metadata: https://www.w3.org/TR/epub-33/#sec-mo-package-metadata (read 2026-11-04)

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