What is .png?
.png (Portable Network Graphics) is a raster graphics file format that supports lossless data compression. It was created as an improved, non-patented replacement for Graphics Interchange Format (GIF) and is the most widely used lossless image compression format on the Internet.
This quick guide explains when to use .png files, how to open them on any device, and how to share them instantly with FileXhost.
When to use .png files
- You need images with transparent backgrounds (logos, icons, overlays).
- You are working with graphics containing text, sharp edges, or solid colors.
- You require high-quality images where no detail can be lost during compression.
How to open .png files
PNG files open natively in all web browsers, operating systems, and image viewers. You can also upload .png files to FileXhost to host them for your website or convert them to other formats.
Algorithm details
PNG uses DEFLATE compression, a non-lossy algorithm that combines LZ77 and Huffman coding. Before compression, a prediction step (filtering) is applied to each scanline to improve compression efficiency. This allows PNG to store images with 100% fidelity to the original data, supporting up to 16 million colors (24-bit RGB) and an 8-bit alpha channel for 256 levels of transparency.
Browser & platform support
- Desktop: Supported by 100% of modern desktop browsers (Chrome, Firefox, Safari, Edge).
- Mobile: Supported by 100% of mobile browsers and operating systems.
- OS: Native support on Windows, macOS, Linux, Android, iOS, and all major platforms.
Format comparison
| Feature | Details |
|---|---|
| File Size | Larger than JPG for photos, but smaller than uncompressed formats like BMP/TIFF. |
| Compression | Lossless. No quality is lost when saving or editing repeatedly. |
| Transparency | Excellent support for alpha transparency (variable opacity), unlike GIF's binary transparency. |
| Animation | Supported via APNG (Animated PNG), though less common than GIF. |
| Text/Lines | Superior to JPG. Text remains crisp and sharp without artifacts. |
How to create png files
- Design Software: Photoshop, Illustrator, Figma, Canva (Export as PNG).
- Screenshots: Default format for screenshots on macOS, Windows, and iOS.
- Converters: Save As PNG from almost any image editor.
- Scanning: Often used for scanning text documents or line art.
How to convert png files
- FileXhost: Upload PNGs to optimize size or convert to JPG/WebP.
- Desktop: Open in Preview/Photos and Export to JPG/PDF/TIFF.
- Online tools: TinyPNG (for compression), CloudConvert, Ezgif.
- CLI: ImageMagick (convert input.jpg output.png), pngquant (optimization).
Advantages & disadvantages
Advantages
- Lossless compression preserves all image details
- Supports alpha transparency (essential for web design)
- Sharp edges and text rendering (no artifacts)
- Wide compatibility and patent-free
- Supports a wide range of color depths (palette-based to truecolor)
Disadvantages
- Larger file sizes compared to JPG for photographs
- Not ideal for high-resolution print (CMYK support is non-standard)
- Animation support (APNG) is not as universally recognized as GIF
- Metadata support is less extensive than TIFF or JPG (EXIF)
Tools & software
Viewers
All web browsers, Windows Photos, macOS Preview, IrfanView
Editors
Adobe Photoshop, GIMP, Paint.NET, Figma, Sketch
Optimizers
TinyPNG, ImageAlpha, Pngquant, OptiPNG
Libraries
libpng, Sharp (Node.js), Pillow (Python), lodepng
Frequently asked questions
Why is my PNG file so big?
PNGs are lossless, meaning they keep every pixel's data. For complex photos, this results in large files. Try converting to JPG or WebP if transparency isn't needed, or run it through an optimizer like TinyPNG.
Does PNG support animation?
Standard PNG does not, but there is an extension called APNG (Animated PNG) that works in most modern browsers. However, GIF is still more commonly used for simple animations.
Is PNG better than JPG for printing?
Generally yes, because it doesn't have compression artifacts. However, for professional printing, TIFF or PDF is often preferred because they support CMYK color spaces better.
Can I convert a JPG to PNG to make the background transparent?
Simply converting the file format won't remove the background. You must use an image editor (like Photoshop or remove.bg) to delete the background pixels first, then save as PNG.
What is PNG-8 vs PNG-24?
PNG-8 uses a palette of up to 256 colors (like GIF), resulting in very small files. PNG-24 supports millions of colors and is better for complex images but produces larger files.
Technical specs
- File type
- Image
- Extension
- .png
- MIME type
- image/png
- Compression
- Lossless
- Max file size on FileXhost
- Up to 25 MB per file on the free plan and up to 1 GB on Pro FileXhost accounts.
Share .png files instantly
Upload your .png file to FileXhost to get a clean, shareable URL in seconds. View the file in a modern browser, protect access with optional settings, and let others download it without any confusing ads or cluttered file pages.
Upload .png file