Why JPG to JXL is a special case
Most format conversions decode an image to pixels and compress those pixels again. With a JPG that means a second round of lossy compression on top of the first, which can only lose detail.
JPEG XL was designed with a specific answer to this problem. Its reference library, libjxl, can take the already compressed contents of a JPEG file — the DCT coefficients, quantisation tables and markers — and store them more efficiently inside a JPEG XL file. The JPEG committee lists this “lossless transcoding” as a core feature of the format and describes typical savings of about 20% (JPEG XL overview, jpeg.org). Because nothing is decoded to pixels and re-quantised, the image you see is exactly the image you had.
This converter uses that path for every JPG by default. It calls libjxl’s JPEG recompression API (JxlEncoderAddJPEGFrame with JPEG reconstruction data, documented in the libjxl encoder API) compiled to WebAssembly, running on your device.
Checked in your browser, file by file
After each JPG is converted, the tool decodes the new .jxl back into a JPEG and compares it with the input, byte by byte. When they match, the result shows “Verified in your browser”. If a check ever failed, you would see a warning and the advice to keep your original — the tool does not quietly assume success.
When to use JPG to JXL
- Archiving photo libraries. You save storage while keeping a path back to the exact original files.
- Backups and cloud storage where every gigabyte counts and you control the software that opens the files.
- Camera JPEGs you want to keep as-is, including EXIF data such as date, camera model and orientation.
When not to (yet)
- As the only image format on a public website, unless you have checked browser support for your audience and provide a fallback (for example with the HTML
<picture>element). - When the recipient’s software cannot open JXL. Sending a
.jxlto someone with an older phone or editor may leave them unable to view it. - If you need smaller files at any cost. Lossless recompression saves a moderate amount. For much smaller files you can choose the Balanced mode — but that re-encodes pixels and gives up the exact-restore guarantee.
Metadata and privacy options
In the default mode all JPEG metadata travels with the image, because it is part of what gets restored. If you choose Remove location (GPS), the GPS fields in EXIF and XMP are blanked before recompression; Remove all metadata removes EXIF, XMP and comments while keeping the colour profile so colours stay correct. In both cases the .jxl restores to your edited JPEG rather than the untouched original, and the metadata report says so.
Tips
- Phone photos with rotation information keep their orientation: libjxl stores it in the JPEG XL header.
- JPGs that are too large for pixel conversion on your device can often still be recompressed, because this path never decodes the image to pixels and needs less memory.
- If you also tick WebP or AVIF, those outputs are made from decoded pixels, so they are lossy re-encodes. Compare them in the results table.
Want the bigger picture first? Read what JPEG XL is, or see how JXL compares with WebP and AVIF.
Last updated:
Frequently asked questions
Does converting JPG to JXL reduce quality?
Not in the default mode. Lossless JPEG recompression keeps the original compressed data, so the pixels are identical to the JPEG's. Only the Visually lossless, Balanced and Custom modes decode and re-encode pixels.
How much smaller will my JPG get?
It depends on the file. The JPEG committee describes lossless JPEG transcoding as saving about 20% on typical photos. The converter shows the exact before and after size for every file, so you can see your own result.
Can I get my original JPG back?
Yes, if you used the default lossless mode and kept all metadata. A JPEG XL decoder that supports JPEG reconstruction (for example libjxl's djxl tool) restores the original file byte for byte. The converter verifies this in your browser after each file.
Why did one JPG fall back to the visually lossless mode?
A few JPEG variants, such as arithmetic-coded or CMYK JPEGs, cannot be recompressed losslessly by libjxl. In that case the tool tells you and converts the pixels at high quality instead.