Command

Convert a file by targeting the output format:

npx optimo image.png --format gif

Tip: add --dry-run to preview changes.

Why convert?

  • GIF is still used for very simple animations and legacy constraints.
  • Useful when you need the GIF container for a specific workflow.

Format notes

PNG

Lossless image format with sharp edges and great support for transparency.

Optimize PNG Compress PNG Resize PNG PNG guide

GIF

Legacy animated image format that is still widely used for simple loops.

Optimize GIF Compress GIF Resize GIF GIF guide