File Optimization for EPUBs

In order to ensure file security via Adobe Content Server (ACS4), files uploaded to NetGalley are converted to .acsm using a process that packages and encrypts the files. 

Due to this encryption process, NetGalley can’t handle files as complex as those you send to a printer, so it’s best to optimize your EPUBs by removing or simplifying large images, layers of graphics or shapes, and embedded fonts.

Places you may be able to trim, if applicable:

  • Reduce image sizes from 300 dpi to a web-friendly resolution of 72dpi
  • Reduce video file sizes (or remove) – ensure they’re optimized for the web
  • Reduce audio file sizes (or remove)
  • Web-optimize any attached PDFs using AcrobatPro (or remove attachments)

We've also uncovered a few specific technical tricks for EPUB files:

  1. Check to make sure the dc:language element is not missing in the metadata section. It's required for the NetGalley upload to work.
  2. Always encode all content documents as UTF-8.
  3. Avoid using any entities other than the five required by XML: nbsp, lt, gt, apos, and amp (if you use UTF-8, you do not need to use any other entities).
  4. In the content.OPF file IF the dc:identifier tag is set for uuid AND the uuid is a 13-digit number THEN the reference to uuid needs to be changed to ISBN.

    For example: Change this tag <dc:identifier id="bookid">uri:isbn:9780062020628</dc:identifier> To: <dc:identifier id="bookid">9780062020628</dc:identifier>

  5. When content files in the EPUB contain a paragraph tag immediately followed by an html entity (such as &ldquo; or &quot; or &nbsp;) there will likely be an error with the ACS server packaging. For example,<p>&ldquo;Sorry.&rdquo;</p>.
  • In many cases, simply following the paragraph tag with a new line will avoid the problem:

<p>

&ldquo;Sorry.&rdquo;</p>

  • However, in other cases, both the beginning paragraph tag and the ending paragraph tag must be on their own lines:

<p>

&ldquo;Sorry.&rdquo;

</p>

The best practice for avoiding this problem is to always place opening and closing paragraph tags on their own lines, in every content document. For most developers, this is a simple find and replace operation across all the content files. In cases where we have these problems, the epub file will have to be edited in this way in order to work with the ACS server and be successfully processed in our system.

To ensure that your EPUB will upload to NetGalley successfully, visit FlightDeck, an automated tool which checks files for distribution to NetGalley and all major retailers. From validation and best practices, to retailer-specific information and metadata editing, FlightDeck reduces your workload and helps you fix file issues quickly.

Was this article helpful?
1 out of 1 found this helpful