PNG vs JPG vs WebP
Three formats cover almost everything. Knowing which to reach for takes about ten seconds once you understand what each one was built to do.
Published
The one-line version
Use JPG for photographs, PNG for anything with sharp edges, text or transparency, and WebP when the destination is a web page and you control what opens it. If you remember nothing else, that rule will be right the overwhelming majority of the time.
Why JPG is still everywhere
JPG was designed in 1992 around a specific insight: human eyes are far more sensitive to brightness than to colour, and barely notice fine detail in busy areas. JPG throws away the information you are least likely to miss, which is why a photograph can shrink to a tenth of its size and still look identical.
That same trick is what makes JPG bad at everything else. Sharp black-on-white text sits at the exact boundary the format handles worst, which is why a screenshot saved as JPG develops a grubby halo around every letter. The compression is not broken — it is doing precisely what it was designed to do, to content it was never designed for.
Why PNG exists
PNG is lossless. Every pixel you put in comes back out, bit for bit, no matter how many times you open and re-save it. It also has a real alpha channel, so parts of the image can be genuinely transparent rather than filled with a background colour.
The cost is size. PNG compresses by finding patterns and repetition, which works beautifully on flat colour, logos, diagrams and screenshots, and works poorly on photographs, where every pixel differs slightly from its neighbour. A photo saved as PNG can easily be five times the size of the JPG for no visible gain.
Where WebP actually wins
WebP does both jobs. It has a lossy mode that generally beats JPG at the same visual quality, and a lossless mode with transparency that generally beats PNG. Typical savings over PNG run between 30% and 70%.
The catch is not browsers — every current browser reads WebP. It is everything else: older desktop software, some printers, some corporate document systems and a long tail of tools that will simply refuse to open the file. If you are publishing to the web, use WebP. If you are sending a file to a person who will open it in something unknown, do not.
The trap almost everyone falls into
Converting a JPG to PNG does not restore quality. It makes the file lossless from that point on, which stops further damage — but the detail the original JPG discarded is gone permanently, and the PNG faithfully preserves every compression artefact along with it. You end up with a much larger file containing exactly the same flaws.
The corollary is the useful bit: if you are going to edit an image repeatedly, work in PNG and export to JPG once at the very end. Every intermediate save in a lossy format compounds the damage.
What happens to transparency
Only PNG, WebP, GIF and ICO carry transparency. Convert any of them to JPG or BMP and those areas have to become something, because the format has nowhere to record "nothing here". Tools differ in what they pick; a surprising number choose black, which ruins logos. This site fills with white deliberately, which is almost always what people expect.
To put this into practice: convert PNG to WebP for lighter web images, convert JPG to PNG when you need a lossless copy, or compress an image without changing its format.