JPG, PNG, WebP or HEIC? Choosing the right image format
Picking an image format is really answering two questions: what kind of picture is this, and where is it going? Get those right and the format chooses itself. This guide walks through the formats you actually meet — JPG, PNG, WebP, HEIC and the specialists — what each is good and terrible at, how to work out what a mystery file really is when its extension lies, and the handful of conversions everyone eventually needs. Every converter linked below runs inside your browser tab; the pictures never leave your device.
The one concept that explains everything: lossy vs lossless
Lossy compression (JPG, WebP in its default mode, HEIC) throws away detail your eye is unlikely to miss — which works brilliantly for photographs, where every pixel differs slightly from its neighbours anyway. Losslesscompression (PNG, GIF, WebP in lossless mode, TIFF) keeps every pixel exact — which is what text, logos, screenshots and UI graphics need, because lossy artefacts smear crisp edges into visible fuzz. Almost every “why does my image look bad?” question is one of these two mismatches: a screenshot saved as JPG (fuzzy text) or a photo saved as PNG (enormous file, no visual gain).
Two details make the lossy side worse than people expect. First, nearly every JPG encoder — the one in your browser included — stores colour at half the resolution of brightness (4:2:0 chroma subsampling), so a red word on a blue button grows a halo: the colour boundary is being drawn at half size. Second, the loss compounds. Each re-save re-quantises the picture, so open, crop, save, open, adjust, save leaves blotches in flat skies after a handful of rounds. Keep an original and export from it rather than re-editing the export.
JPG — the photograph workhorse
The JPEG standard (ITU-T T.81) dates from 1992 and nothing has displaced it since. A file that starts with the bytes FF D8 FFcompresses a photo to roughly a tenth of its raw size with barely visible loss, every device and website accepts it, and printers and photo labs expect it. The spec allows up to 65,535 pixels a side, 8 bits per channel in practice, no transparency and no animation. Quality is a 1–100 dial: 80–85 is the sweet spot for photos on the web, and above about 92 the file grows quickly for no visible gain. The site’s image-to-JPG converterexposes that dial as a “Quality” slider in the save dialog, defaulting to 92%; batch conversions of several files encode at the same 92. It reads PNG, WebP, GIF, BMP, TIFF, SVG, ICO, PSD, AVIF and HEIC — the formats a browser cannot display natively (TIFF, PSD) are decoded on your device by a WebAssembly build of ImageMagick before the editor opens.
PNG — screenshots, logos, transparency
PNG is lossless and supports full alpha transparency, which makes it the default for screenshots, diagrams, logos and any graphic that overlays another background. It begins with 89 50 4E 47 0D 0A 1A 0A — you will see .PNG in a hex viewer — and compresses with DEFLATE, the algorithm inside ZIP files, plus per-row filters. That is why a screenshot of a text-heavy window, which is mostly runs of the same flat colour, often ends up smaller as a PNG than as a JPG, and looks perfect where the JPG looks fuzzy. The cost shows up on photographs: a photo saved as PNG is routinely five to ten times larger than the visually identical JPG. Rule of thumb — made by a camera: JPG (or WebP/HEIC); made by a computer: PNG. The PNG converter keeps transparency from WebP, GIF or SVG sources intact; note that the browser writes a 32-bit RGBA PNG, so a flat-colour graphic can be squeezed further by a dedicated palette optimiser if the last kilobyte matters.
WebP — the modern web default
WebP does both jobs — lossy like JPG, and in Google’s own comparison 25–34% smaller at the same quality; lossless like PNG, about 26% smaller there too — with transparency and animation on top. A WebP begins RIFF, four bytes of length, then WEBP. Every current browser displays it (Safari was the last to arrive, in version 14 in 2020), which is why site builders and CDNs push it hard. Where it still stumbles: older desktop software, some email clients and print workflows. Photoshop only learnt WebP in version 23.2 (February 2022); earlier versions answer with “Could not complete your request because it is not the right kind of document.” It also has a hard ceiling of 16,383 pixels a side, so a large scan or a stitched panorama simply cannot be a WebP. So: publish WebP on the web via the WebP converter, but when a form, an old CMS or a print shop rejects it, convert back to JPG or PNG.
HEIC — the iPhone surprise
Since iOS 11 (2017) iPhones shoot HEIC by default: a single HEVC (H.265) video frame wrapped in a HEIF container, roughly half the size of a JPG at the same quality, which is why Apple chose it. Bytes 4 to 11 of the file read ftypheic (or ftypmif1). The catch appears the moment the photo leaves the Apple ecosystem. Windows Photos stops with “The HEIF Image Extension is required to display this file” and then needs the separately sold HEVC Video Extensions as well; Chrome and Firefox will not render a HEIC in an <img> tag at all; many web forms and government portals reject the extension outright. You can stop the phone producing them under Settings → Camera → Formats → Most Compatible, at the cost of larger files.
The practical fix is a local conversion. The HEIC to JPG converter decodes the photo with libheif compiled to WebAssembly, inside your browser, then saves a normal JPG; select a whole camera roll and it converts them in sequence into one ZIP. The still image comes through intact — what cannot come through is the Live Photo motion or depth data, because JPG has nowhere to put them. The HEIC guide covers the Windows codec situation and the iPhone settings in detail.
The specialists: GIF, TIFF, BMP, ICO, SVG
GIF (GIF89a or GIF87a as its first six bytes) survives purely for simple animations; each frame is limited to a 256-colour palette and transparency is on/off with no soft edges, so for still photos it is the wrong answer. If a forum or an old dashboard insists, the image-to-GIF converter writes a single-frame GIF through ImageMagick; animated GIFs come from video instead — see making a GIF from a video.
TIFF (II*\0 or MM\0*at the start, depending on byte order) is the print and scanning industry’s lossless container: huge files, high bit depths, expected by publishers and journals. Use the TIFF converter when a print shop or a journal names it. BMP (BM) is essentially uncompressed pixels — a 4032 × 3024 iPhone photo becomes 36.6 MB (4032 × 3024 × 3 bytes plus a 54-byte header) — which is exactly why firmware, e-paper projects and image-processing coursework like it; the BMP converter exists for them.
ICO (00 00 01 00) is exclusively for favicons and Windows icons. The format can hold several sizes in one file and tops out at 256 × 256; the ICO converter downscales anything larger with ImageMagick’s -resize 256x256> and keeps transparency, and the favicon guide covers the full set of sizes a modern site needs. SVG is not pixels at all but a text file of vector instructions — it starts with <?xml or <svg — infinitely scalable logos and icons, unbeatable where it applies, and not a photo format. Every image tool here accepts an SVG as input and rasterises it; the image-to-SVG page opens a raster in the same editor but does not trace pixels into vector paths — nothing on this site does — so a photo never becomes a scalable drawing. A word on AVIF: the newest web format, smaller again than WebP, supported by Safari since 16.4 (2023); the tools here read it as input but do not write it.
Side by side
| Format | Compression | Transparency | Limits | Use it for |
|---|---|---|---|---|
| JPG | Lossy | No | 65,535 px a side, 8-bit | Photos for anything and anyone |
| PNG | Lossless | Full alpha | Big files for photos | Screenshots, logos, diagrams, cut-outs |
| WebP | Lossy or lossless | Full alpha | 16,383 px a side; older software | Anything on a web page |
| HEIC | Lossy (HEVC) | Yes | Apple-only in practice | Storing photos on an iPhone — convert before sharing |
| GIF | Lossless, 256 colours | On/off only | No photos | Short simple animations |
| TIFF | Lossless | Yes | Huge; no browser support | Print, scanning, archives |
| BMP | None | No (in practice) | Enormous | Legacy Windows, firmware, coursework |
| ICO | Container (PNG/BMP inside) | Yes | 256 × 256 max | Favicons, Windows icons |
| SVG | Vector text | Yes | Not for photos | Logos, icons, illustrations |
The quick answers, then:
- Photo for a website or WhatsApp: JPG or WebP at quality 80 — visually identical to the original at a fraction of the size. The image compressor does this in one tick: it encodes at quality 72 and pulls anything longer than 2,560 px on its longest side down to that, or you can type a hard cap in kilobytes and it searches for the highest quality that fits.
- Screenshot with text: PNG, always.
- Logo that sits on any background: PNG or SVG, for the transparency.
- iPhone photo a form rejects: HEIC → JPG.
- Image for print:TIFF or maximum-quality JPG at 300 pixels per inch, per your printer’s instructions.
- Favicon: ICO, from a square source.
How to tell what a file really is
The extension is a label, not a fact. Android and WhatsApp hand out WebP files named .jpg; people “convert” HEIC by renaming it; a download called logo.png is sometimes a JPG with the wrong name. The honest answer is in the first dozen bytes, and every operating system can show them:
# macOS / Linux
file photo.jpg
# photo.jpg: JPEG image data, Exif standard: ...
xxd -l 12 photo.jpg
# 00000000: ffd8 ffe1 0a1e 4578 6966 0000 ......Exif.. (bytes 5–6 vary)
# Windows PowerShell
Format-Hex -Path photo.jpg -Count 16| Format | First bytes (hex) | What the text column shows |
|---|---|---|
| JPG | FF D8 FF | ÿØÿ then JFIF or Exif |
| PNG | 89 50 4E 47 0D 0A 1A 0A | .PNG.... |
| GIF | 47 49 46 38 39 61 | GIF89a (or GIF87a) |
| WebP | 52 49 46 46 ·· ·· ·· ·· 57 45 42 50 | RIFF....WEBP |
| HEIC | 00 00 00 ·· 66 74 79 70 68 65 69 63 | ....ftypheic (or ftypmif1) |
| AVIF | 00 00 00 ·· 66 74 79 70 61 76 69 66 | ....ftypavif |
| TIFF | 49 49 2A 00 or 4D 4D 00 2A | II*. or MM.* |
| BMP | 42 4D | BM |
| ICO | 00 00 01 00 | (nothing printable) |
| SVG | 3C 3F 78 6D 6C or 3C 73 76 67 | <?xml or <svg |
The error message narrows it down too. “The HEIF Image Extension is required to display this file” from Windows Photos means HEIC. A broken-image icon in an old Safari, or Photoshop’s “not the right kind of document”, usually means WebP. An upload form listing “jpg, jpeg, png, gif” wants a conversion, not a rename. The converters on this site have their own tells: “Could not read this HEIC photo. The file may be corrupted or use an unsupported HEIC variant” means libheif rejected it (a Mac’s Preview is the fallback), while “Could not read this image. The file may be corrupted or in a format this browser cannot decode” on something called .jpg is almost always a renamed HEIC — see the first mistake below.
Common mistakes
- Renaming
.heicto.jpg. Nothing inside the file changes. The converters here route by extension or MIME type: a real.heicgoes to libheif, but a renamed one is handed to the browser, fails, then falls to the ImageMagick build, which predates HEIC — hence “Could not read this image”. Rename it back and drop it again. - Expecting JPG → PNG to restore quality. The detail is gone; PNG merely stops further loss. Go back to the original if there is one.
- Converting a transparent PNG to JPG without thinking about the background.JPG has no alpha channel, so something must be painted behind the picture. This site’s batch converter fills it white; many other tools fill it black. If the background matters, stay with PNG or WebP.
- Ticking “Compress image” with PNG selected.PNG has no quality knob, so the tick only shrinks dimensions above 2,560 px and the bytes barely move. Switch the format to JPG or WebP. Likewise, typing a “Max file size (KB)” while PNG is selected gives you a JPG — a byte cap is impossible without a quality dial.
- Opening a 24-megapixel camera file in the editor and losing resolution.The single-image editor caps the working copy at 4,096 px on the long edge so a phone can save it, and says so: “Large image resized to … so it can be edited and saved on this device.” To keep full resolution, select two or more files and choose “Convert all to … (ZIP)” — the batch path has no such cap.
- Making a favicon from a wide logo. ICO wants a square; crop first, or the 256-pixel downscale leaves a thin strip.
Do this
- Camera photo: JPG (or WebP for a web page) at quality 80–85; keep the original, export from it, never re-save the export.
- Screenshot, logo, diagram or anything with text: PNG. Transparent logo: PNG or SVG.
- iPhone HEIC a form rejects: convert to JPG locally, and switch the phone to Most Compatible if it keeps happening.
- Mystery file: check the first bytes with
file,xxdorFormat-Hexbefore you trust the extension. - Print: TIFF or maximum-quality JPG at 300 ppi, sized to the printer’s spec.
- Need a smaller file: shrink the pixel dimensions first, then lower quality; a size cap in KB does both automatically.
Frequently asked questions
Is WebP better than JPG?
On a web page, usually yes: at the same visual quality a lossy WebP is typically 25–34% smaller than a JPG, and it can carry transparency, which JPG cannot. For files you hand to other people, JPG is still the safer choice — older desktop software, some email clients and most print shops still cannot open WebP.
Why will my iPhone photo not open on Windows?
Because it is a HEIC file, the format iPhones have shot by default since iOS 11. Windows Photos needs the HEIF Image Extension and the HEVC Video Extensions from the Microsoft Store before it can decode one. Converting the photo to JPG in your browser sidesteps the whole problem.
Does converting PNG to JPG lose quality?
A little, every time. JPG is lossy, so fine detail and sharp edges are approximated, and text or line art goes visibly fuzzy. Converting the JPG back to PNG afterwards restores nothing. Keep the PNG as your master and hand out the JPG.
Which image format is best for printing?
TIFF or a maximum-quality JPG, at the pixel dimensions your printer asks for — the usual rule is 300 pixels per inch of finished print. Ask first: most print services accept JPG and PDF, and only a few insist on TIFF.
Can I convert HEIC to JPG without uploading my photos?
Yes. The HEIC converter on this site decodes the file with libheif compiled to WebAssembly inside your browser tab and saves a normal JPG to your device. Nothing is sent to a server, and once the decoder has loaded it keeps working with Wi-Fi switched off.
Tools used in this guide
Every one of these runs in your browser — the files you work on never leave your device.