No image format is best for every asset. Photographs, line art, logos, and transparent overlays have different compression and compatibility needs.

Select by content and support

  • Use a modern photographic format when the image pipeline and target browsers support it.
  • Keep transparency when the design requires it, and compare the edges against the page background.
  • Use SVG for appropriate vector graphics, not as a container for untrusted user uploads.

Check visual quality and file size together. Provide an appropriate fallback when the project's browser support policy requires one, and do not convert a sharp logo into a blurry raster unnecessarily.