PNG or JPG - which one should I use?

If you take a minute to think about what you are doing and what your needs are, you can easily choose between these (or any other formats).

About PNG

 

PNG initials Portable Network Graphics. It is one of the most well-known and used image file format of all beside jpg and gif. The extension is used logically as .png. PNG was born as a royalty free version of GIF, because the applied algorithm in GIF was set to payment and they wanted to get around this problem. Therefore, they developed PNG which used an algorithm free of charges. It all happened in 1996.

 

About JPG

 

JPEG/JPG initials Joint Photographic Experts Group. As we mentioned before, it is one if not the most commonly used file format to store images. The extension that is used for this format is either .jpg or .jpeg as they both work the same way except for the one letter difference. Jpeg/jpg was first formed in 1992 so it is slightly older than png.

 

When should PNG be used?

 

Png algorithm uses compression that is lossless thanks to the way it stores pixels on the bases of colours. It is a great possibility for those who seek a way to store and reprocess their photos, images without losing any information, accordingly losing no quality.

 

 

The question of size durance is a different thing. When we store a computer generated image in png format, it will possibly have a relatively small storage size, but for example in the case of a scanned image it is practical to store it in a different format for example, as a jpeg as colours might differ very much.

 

Why JPG?

 

Photographers still like to use jpg, because of its usefulness in storing images with a vivid colour scheme. In case of having images with sharp edges it is better to use a different format like png, because there will be a higher chance for a lossy result in the end. Compression is a good thing when it comes to storing and size, and a jpg or jpeg file will only take up a few MBs, so if the loss is vanishing or not important, you can easily store your pictures as jpg files.

 

Image format infograph

 

Conclusion

 

Both PNG and JPG/JPEG have their own advantages and disadvantages. If you take a minute to think about what you are doing and what your needs are, you can easily choose between these (or any other formats). You store a lot of images without caring about information loss? Go for JPG! You care about quality but the size is irrelevant? Go for PNG!

Guides, cheatsheets and tips about the increasingly important role of images in modern web design. Follow me on Twitter and Facebook too, for more handy content!

You might also like
Browser alert for uploading complete folders
Shardimage.com 1 min read
If you're using Chrome - and, according to browser usage share statistics, you're more likely to do so, than not - you've...
Referral source URLs for Google Images updated
Shardimage.com 1 min read
Google decided to roll out a new referrel URL that is specific to Google Images over the course of the next few months.
Security first - why should you restrict your API keys?
Shardimage.com 2 min read
Your API keys are the primary way Shardimage authenticates your access to the platform's APIs and SDKs.