JPG vs PNG vs WebP: which image format should you use?
JPG, PNG and WebP compared on compression, transparency, animation, compatibility and file size, with a simple rule for picking the right one.
· 5 min read
The short answer: use JPG for photos you share, upload or print; PNG for screenshots, logos and anything with transparency or sharp text; and WebP for images on your own website. The rest of this guide explains why, and covers the cases where the answer changes.
At a glance
| Feature | JPG | PNG | WebP |
|---|---|---|---|
| Compression | Lossy | Lossless | Lossy or lossless |
| Transparency | No | Yes | Yes, in both modes |
| Animation | No | Only as APNG | Yes |
| Color depth | 8 bits per channel | Up to 16 bits per channel | 8 bits per channel |
| Largest image | 65,535 × 65,535 px | Practically unlimited | 16,383 × 16,383 px |
| Web browsers | All | All | All modern browsers |
| Apps and upload forms | Everywhere | Everywhere | Most current apps; some forms and older software refuse it |
| Photo file size | Small | Large, often 5–10× a JPG | Smallest, usually 25–35% below JPG |
JPG: the universal photo format
JPG (or JPEG, the same thing) dates from 1992 and is still the format every camera, phone, app, printer and upload form understands. It splits the image into small blocks and stores each block as a mix of smooth patterns, keeping the strong ones and rounding away the faint ones. It also stores color in less detail than brightness, because our eyes do the same.
That works beautifully for photos, where natural detail hides the losses. It works badly for sharp edges: text, lines and flat-colored graphics pick up fuzzy “ringing” around them. JPG has no transparency, so transparent areas become a solid color, usually white. And because it is lossy, every re-save loses a little more detail.
Use JPG for: photos to email, upload, print or share, and any time a form simply says “JPG”. Graviton encodes JPGs with MozJPEG, which makes them about 10% smaller than standard encoders while staying fully compatible. Try it with compress JPEG.
PNG: exact pixels and transparency
PNG appeared in 1996 as a patent-free replacement for GIF. It is lossless: every pixel is stored exactly, with full transparency, including soft edges and shadows. That makes it the right format for screenshots, interface graphics, logos, diagrams, and images you will keep editing.
The catch is photos. Lossless compression cannot do much with natural noise, so a PNG photo is often five to ten times the size of a JPG that looks the same. When a PNG must stay a PNG, the most effective trick is palette reduction: storing the image with up to 256 carefully chosen colors. Graviton picks the palette, adds subtle dithering so gradients stay smooth, then squeezes the file further with OxiPNG. Screenshots and graphics usually lose 60–80% of their size this way with no visible change.
Use PNG for: screenshots, logos, graphics with text, transparent cutouts, and editing masters.
WebP: built for the web
Google released WebP in 2010. Its lossy mode is based on the VP8 video codec and its lossless mode is a separate design, and both support transparency and animation. Google’s own measurements put lossy WebP at 25–34% smaller than JPG at equal quality, and lossless WebP at about a quarter smaller than PNG.
Every modern browser displays WebP, so for your own website it is a safe default. Two caveats. First, lossy WebP always stores color at reduced resolution, which can soften thin red or blue details; Graviton uses libwebp’s sharp color conversion to reduce this. Second, WebP is still rejected by some upload forms, older photo editors and office software, which is why images saved from websites as .webp are often converted back to JPG.
Use WebP for: photos and graphics on websites, blogs and online stores.
JPG to WebP converterTurn JPG photos into WebP files that are usually 25–35% smaller, right in your browser.Which format for which job
| Job | Best choice | Why |
|---|---|---|
| Photo for email or an upload form | JPG | Accepted everywhere, small enough |
| Photo on your website | WebP (or AVIF with a fallback) | Smallest files every browser can show |
| Screenshot with text | PNG | Text stays crisp |
| Logo or icon with transparency | PNG, or WebP on the web | Keeps transparent edges (SVG is better still for vector logos) |
| Image you will edit again | PNG | No loss between saves |
| iPhone photo to share | JPG | HEIC does not open on many devices |
| Short animation | GIF, or animated WebP on the web | GIF works everywhere; WebP is much smaller |
Extensions can be misleading
A file’s extension is only a label. .jpg and .jpeg are the same format, and so is .jfif, which some browsers on Windows use when saving images. Images saved from websites are often WebP even when they look like an ordinary photo, because sites serve WebP to browsers that support it. And a WebP renamed to .jpg is still a WebP, which is why some apps refuse to open it.
If an app rejects an image that looks fine, convert it properly rather than renaming it. Graviton reads each file’s actual contents to identify its format, then writes a genuine JPG, PNG, WebP or AVIF.
What about AVIF?
AVIF is the newest of the web formats and is often around half the size of a JPG. It is supported by current versions of all major browsers but by fewer apps, and it is slower to encode. For websites it is an excellent choice alongside a WebP or JPG fallback. Read what AVIF is for the details.
Converting between formats
- JPG to PNG keeps the image exactly as it is but cannot restore detail the JPG already lost, and the file gets bigger.
- PNG to JPG makes photos and large screenshots much smaller, but transparent areas turn white. Try PNG to JPG.
- WebP to JPG is the fix when an app or form refuses a WebP. Use WebP to JPG.
- PNG to WebP shrinks website graphics while keeping transparency, with PNG to WebP.
Graviton converts between all of these inside your browser, so your images are never uploaded. Converting is unlimited and needs no account, and a free account covers 3 downloads a day with every format.
WebP to JPG converterGot a WebP that won’t open? Turn it into a JPG that every app and form accepts.