Skip to content

Auto Parameters

The auto parameter enables automatic image optimisation modes. Options can be combined as a comma-separated list:

  • optimize
  • format
  • ssim

Applies best-effort techniques to reduce image size while maintaining quality. The optimiser starts at a default quality target of q=75, but can hand off to the machine-learning quality predictor when you supply q=auto. When combined with auto=format, browser capability hints are also considered.

Converts images to the most appropriate output format for each request. The optimiser evaluates browser support, transparency, and animation before selecting JPEG, PNG, WebP, AVIF, or JXL. Pair with auto=optimize and q=auto to let both format and quality adapt to the request.

Enables SSIM-driven format selection when SSIM support is enabled in the runtime. The optimiser compares candidate formats and chooses the best SSIM-per-byte tradeoff.

Validation Rules

  • auto=ssim by itself does not trigger format selection; use auto=format,ssim.
  • auto=format,ssim cannot be combined with an explicit fm parameter.

ML-Driven Quality (q=auto)

Set q=auto (or the preset variants auto:low, auto:med, auto:high) to enable the machine-learning quality predictor. The optimiser analyses the source image, estimates the smallest acceptable file size, and chooses an output quality that stays within the requested band. Combine q=auto with auto=optimize to automatically balance fidelity and performance without hand-tuning quality values.