背景が透明な画像を扱うときの注意(PNG→JPG)
- JPGは透明に対応していないため、白で埋められる
- 透明を残したいなら、PNGのままにする
- 背景色を白以外にしたいなら、別の編集が必要
背景が透明な画像(ロゴや、イラストなど)を、JPGに変換すると、背景が白くなります。意図せず、見た目が変わってしまうことがあるので、注意点をまとめます。画像の形式を変換(JPG・PNG・WebP) での扱い方を説明します。
透明とは何か
透明な背景とは、画像の「何もない部分」が、下の色をそのまま見せる状態です。ウェブサイトの背景色や、スライドの色の上に、ロゴを自然に重ねられます。PNGやWebPは、この透明を保てますが、JPGは、保てません。
変換すると何が起こるか
- PNG → JPG:透明な部分が、白になります。
- PNG → WebP:透明を保てます(WebPが作れるブラウザの場合)。
- JPG → PNG:もともと透明ではないので、白い背景は、白のままです。
手順
- 「画像を選ぶ」で、画像を選びます。
- 透明を残したいなら、「変換後の形式」を、PNGにします。JPGにすると、背景が白になります。
- 「変換する」を押して、結果を確認します。
JPGにしてよいか、迷ったら
- 白い背景の場所に貼るなら:JPGでも、問題ありません。
- 色のある背景や、写真の上に重ねるなら:PNGのままにします。
- フォームで、JPGしか受け付けないなら:白い背景で出して、問題ないか、確認します。
背景を、別の色にしたいとき
JPGに変換すると、白になります。ほかの色にしたいときは、画像の編集ソフトで、背景色を先に付けてから、変換します。
つまずきやすい点
- 変換後に、白い枠が出た:透明が、白に置き換わったためです。
- ふちが、ギザギザに見える:透明な画像を、別の背景に重ねたときに、境目が出ることがあります。
- ファイルが、重すぎる:透明が要らないなら、JPGにすると、軽くなります。
よくある質問
透明を、あとから戻せますか?
JPGにしたあとは、戻せません。元のPNGを、残しておきましょう。
半透明も、保てますか?
PNGでは、保てます。JPGでは、白と混ざります。
まとめ
透明を残したいなら、PNG。JPGにすると、背景が白になります。変換する前に、使い先の背景を、確認しましょう。
画像の形式を変換(JPG・PNG・WebP)を使う(無料)あわせて使えるツール
- HEIC画像をJPGに変換:iPhoneで撮ったHEIC画像を、JPGやPNGに変換します。
- 画像を圧縮・サイズ変更:画像のファイルサイズを小さくします。大きさの変更もできます。
- 画像の切り抜き・回転:画像を、好きな範囲や比率で切り抜きます。回転もできます。
同じツールの、ほかの解説
Notes on Handling Transparent-Background Images (PNG to JPG)
- JPG doesn't support transparency, so it is filled with white
- Keep it PNG to preserve transparency
- A non-white background needs separate editing
When you convert an image with a transparent background, such as a logo or an illustration, to JPG, the background turns white. The look can change unintentionally, so here are the points to note. This explains how to handle it in Convert Image Format (JPG, PNG, WebP).
What transparency is
A transparent background means the "empty" part of the image shows whatever colour is underneath. A logo can be laid naturally over a website's background colour or a slide's colour. PNG and WebP can keep this transparency, but JPG cannot.
What happens when you convert
- PNG to JPG: transparent areas become white.
- PNG to WebP: transparency is kept (in a browser that can create WebP).
- JPG to PNG: it was never transparent, so a white background stays white.
Steps
- With "Choose images", select the image.
- To keep transparency, set "Output format" to PNG. With JPG, the background becomes white.
- Press "Convert" and check the result.
When unsure about using JPG
- Placing it on a white background: JPG is fine.
- Laying it over a coloured background or a photo: keep it as PNG.
- A form that accepts only JPG: check that submitting it with a white background is acceptable.
When you want another background colour
Converting to JPG makes it white. To use another colour, add the background colour in an image editor first, then convert.
Common stumbling blocks
- A white box appeared after conversion: transparency was replaced with white.
- The edges look jagged: laying a transparent image over another background can show a boundary.
- The file is too heavy: if you do not need transparency, JPG makes it lighter.
Frequently asked questions
Can I restore transparency later?
Not after converting to JPG. Keep the original PNG.
Is semi-transparency kept?
In PNG, yes. In JPG, it is mixed with white.
Summary
To keep transparency, use PNG. With JPG the background becomes white. Check the background where it will be used before converting.
Use "Convert Image Format (JPG, PNG, WebP)" (free)Tools that go well with this
- Convert HEIC to JPG: Convert HEIC photos from iPhone to JPG or PNG.
- Compress & Resize Images: Make image files smaller, and resize them if you like.
- Crop & Rotate Image: Crop an image to any area or ratio, and rotate it.