Skip to content
ComPDF
DemoSampleAPI ReferenceFAQ

PDF Generation Template Editor

Open-source visual PDF generation engine with customizable templates and developer-friendly APIs.

View on GitHub

Overview

ComPDFKit provides powerful PDF document compression and optimization functionality. Through the CPDFOptimizeOption class, you can finely control compression behavior to effectively reduce file size for easier storage and transmission.

Benefits of ComPDFKit Document Compression

  • Fine-grained Image Compression: Support multiple compression algorithms (JPEG, JPEG2000, JBIG2, CCITT3/4), adjustable image quality, resolution, and block size.
  • Rich Optimization Flags: Provides 30+ optimization flags, supporting removal of unused resources, cleaning metadata, merging layers, and other operations.
  • Progress Callback Support: Get real-time compression progress through delegate functions, with support for cancellation.
  • Web Optimization: Support PDF linearization for fast web viewing.

Guides for Document Compression