4 Reasons Why Your PNG Files Aren’t Transparent

A transparent PNG can be an incredibly useful tool for any business or individual. Logo PNGs with no background can be placed on promotional graphics and products without having to worry about unsightly borders. If you’ve ever dabbled in graphic design, you’ve probably asked, “Why is my PNG not transparent?” too many times.

PNGs can lose their transparency in a number of ways, from being read incorrectly in a browser, to compression, to incompatible conversions. There are a few solutions you can use for each scenario to retain the transparency of an image.

Here are the four reasons why your PNG files aren’t transparent.

1. Browser PNG Transparency Issues

Some browsers, such as Chrome or Firefox, have issues reading transparency in PNG files if they’re not tagged correctly in the image optimization exclusion list. Your browser may read the image as AVIF, a newer optimized format for browsers that reduces file size. Unfortunately, reading the file in this way loses details and transparency in compression.

The easiest way to solve this is by adding “.png” to your comma-separated exclusion list. This should allow the browser to read the full PNG without compressing it, so the transparency will transfer to the final image. Be aware that allowing your browser to read an image as a PNG may cause loading speed issues. PNGs are larger files, and may take time to load in or may not load at all.

These issues may also be caused by other settings, and will vary from browser to browser. To see whether a particular image will load correctly in your chosen browser, you can look up a PNG transparency test. These tests include a selection of PNG images with different settings, including bit size (from 8 to 64) and transparency modes (more on that below).

Simply open the test in your browser and find the image with matching settings to the PNG you wish to upload. This will show you how it will look. From there, you can see which settings look best on a particular browser and adjust your image accordingly.

2. Compression Loses PNG Transparency                                                   

As mentioned, compression can cause a loss of transparency with PNG images. If a PNG is compressed enough, the details of the image will be lost, and it may appear to have a black background that cannot be easily removed.

The solution to this would be to use a specifically transparent-friendly compression software that will bring the compression along to the smaller file size. You’ll also want to make sure that your image remains a PNG, as JPGs don’t often support transparency at any size.

You may also choose to make your image smaller from the beginning. Be aware, though, that this will mean the PNG retains less detail overall and may appear blurry or pixelated when shown on larger screens.

3. Conversion to JPG Loses Transparency

JPG is a significantly smaller file size than a PNG. If done correctly, you can convert a PNG image to a JPG file without losing quality up to a certain size. Unfortunately, there are some things you simply can’t transfer to a JPG, and transparency is one of them. Transparent backgrounds are not supported at all in JPG images.

Some websites may require JPG files instead of PNGs and may convert your image automatically. This means that the transparency of the background on your image will be lost in translation from one format to the next.

There’s no easy way to prevent this with uploads. However, if you’re using an editor, you can simply check to make sure your image is exporting in PNG format rather than being converted upon saving. Unfortunately, transferring an image back into a PNG format will usually mean having to redo the background’s transparency.

4. Using Alpha Channel Transparency Instead of Indexed Mode Transparency

There are different ways to make a PNG image transparent. Some PNGs use alpha channels to determine color; this means that a percentage of opacity is assigned to a certain layer of color from 100% (totally opaque) to 0% (totally transparent). Setting the background of a PNG image to 0% in the alpha channel causes it to become transparent.

Unfortunately, some browsers do not read alpha channel PNGs correctly. Instead of being transparent, a 0% background will be read as black, and the image will lose its transparency. In order to maintain it, the PNG can be converted to indexed mode coloration. This means that the colors are managed by a background code system that saves the computer memory and makes the file size smaller.

To convert an image to indexed mode, you can use an editing software. Most programs will have an option to select the color-coding method or mode for your image before it’s exported, giving you more control over the color arrangement and retention. For example, if using GIMP, you can select “Image,” then go to “Mode” and select “Indexed.”

How Placeit Can Help

Online graphic design tools are becoming more common, and Placeit is one of the best.

Placeit has three goals – make it easy, make it repeatable, and make it affordable.

Placeit allows you to click “Background Color” and then “Transparent” to remove the background of your design in a single click.

They have over 90,000+ pre-made templates to customize, and you can download them straight to your computer.

Hopefully this article helps you create, and use, your PNGs with a transparent background.