How to Keep Transparency When Converting PNG to JPG (or Use Better Formats)

How to Keep Transparency When Converting PNG to JPG (or Use Better Formats)

1vs Team Updated 2026-08-21 image-converter

JPG cannot preserve transparency — pick a background color in CloudConvert or Photopea. Use WebP or PNG if you need transparency.

Step-by-step

1

Accept that JPG cannot keep transparency

This is the most common surprise for first-time PNG-to-JPG converters. JPG (Joint Photographic Experts Group) is a lossy format designed for photographs — it has no concept of an alpha channel. Every pixel must be a solid color. When you convert a PNG with a transparent background to JPG, the transparent pixels must be flattened to some other color — white, black, or whatever the converter defaults to. CloudConvert and Photopea both make this flattening explicit by asking for a background color before conversion. There is no setting, option, or tool that preserves transparency in a JPG. Plan accordingly: if transparency is critical, do not use JPG.

2

Pick the background color the JPG should fill transparency with

If you must convert to JPG, choose the background color carefully. The wrong color shows up as a halo around logo edges and ruins the result. CloudConvert lets you pick a background color before conversion — white is the safest default for logos placed on light websites. Photopea (free browser editor) shows a live preview against different backgrounds, so you can visually pick the right one. For logos, match the destination background color of the website or app where the JPG will be displayed.

3

Use WebP instead of JPG for transparency

Use WebP instead of JPG for transparency

WebP is Google's modern image format and supports transparency with smaller file sizes than PNG. Convert the PNG to WebP using Squoosh — output is typically 25-35% smaller than the source PNG at equivalent visual quality. WebP is supported by all modern browsers (95%+ of users as of 2026). Use it for any web asset that previously needed PNG transparency. Fall back to PNG only for software that does not support WebP (some email clients, older CMS exports).

4

Use PNG when transparency must be preserved everywhere

Use PNG when transparency must be preserved everywhere

If the destination absolutely must support transparency and cannot use WebP, keep the file as PNG. PNG preserves the alpha channel exactly, with no quality loss. File size is larger than JPG but the visual result is correct. Tools like Squoosh and Photopea preserve the alpha channel automatically when output is PNG. PNG is the right choice for: logos in PDF documents, graphics embedded in Word or PowerPoint exports, icons that ship with desktop software, and any workflow that does not yet support WebP. Do not convert to JPG if transparency is required — there is no workaround.

5

Build a transparency-preserving CMS workflow

For websites and apps that handle many PNG uploads, configure the asset pipeline to serve multiple formats: PNG as the source master, WebP for modern browsers, JPG as a fallback for legacy clients. The HTML picture element handles this: ``. Build the JPG fallback once with Squoosh or CloudConvert and let the server pick WebP or JPG based on the request's Accept header. This preserves transparency for modern browsers while maintaining universal compatibility.

Recommended Tools

FAQ

Can JPG files have transparency?
No — JPG is a lossy format designed for photographs and has no concept of an alpha channel. Every JPG pixel is a solid color. When converting from PNG, transparent areas must be flattened to white, black, or a chosen color. To preserve transparency, use PNG (lossless) or WebP (modern, smaller files).
What happens to transparent pixels when converting PNG to JPG?
Every transparent pixel is replaced with a solid color — typically white, black, or whatever the converter's default is. CloudConvert lets you pick the background color before conversion. The wrong color choice creates a visible halo around logo edges. Use Photopea to preview the flattened result against the destination background before exporting.
What format should I use instead of JPG to keep transparency?
WebP is the best modern choice — it supports transparency with 25-35% smaller files than PNG at equivalent quality, and is supported by all modern browsers. PNG remains the universal fallback for software that does not yet support WebP. Never use JPG if transparency is required — there is no workaround.
How do I convert PNG to JPG with a white background?
Use CloudConvert — open the PNG, pick JPG as the output format, and select white as the background color before clicking Convert. The transparent pixels in the PNG become white in the JPG. Photopea gives a live preview against white, which is useful for verifying the result looks right before saving.
Does Photoshop preserve transparency when exporting PNG to JPG?
No — Photoshop flattens transparent pixels to a solid color during JPG export. In Export As, click the matte color box and pick white, black, or a custom color. Photoshop also supports saving as WebP with transparency preserved, which is a better choice when transparency matters. For PNG masters, keep the layered PSD file as the source of truth.

Related