Glossary Design & Media

WebP

WebP is a modern image format from Google that supports lossy and lossless compression, transparency and animation in smaller files than JPEG or PNG.

Last reviewed:

AdSense Placeholder
Slot: header_reference_page

In more detail

WebP has two codecs: lossy WebP is based on the VP8 video codec, and lossless WebP uses a separate method closer to PNG. Both can carry an alpha channel, and an extended format adds animation and metadata such as EXIF and colour profiles. Google reports that lossless WebP files are about 26% smaller than PNG, and lossy files 25–34% smaller than comparable JPEGs; real savings depend on the image.

Why it matters

All current browsers display it, so it is a common default for web images and an alternative to animated GIFs. Some desktop programs, older systems and upload forms still reject it, which is why images saved from websites sometimes need converting to JPEG or PNG. Converting a lossy WebP to PNG does not restore lost quality; it only makes a larger file of the same pixels.

Example

A WebP file is a RIFF container. The first 16 bytes of a small lossy image were:

52 49 46 46 4A 00 00 00 57 45 42 50 56 50 38 20   RIFFJ...WEBPVP8

RIFF, then the file size minus 8 as a little-endian number (4A 00 00 00 = 74, for an 82-byte file), then WEBP. The chunk name VP8 marks lossy data; lossless files have VP8L and extended ones VP8X.

AdSense Placeholder
Slot: footer_leaderboard