Artists and graphic designers use PGM files to store small 2D images in grayscale. Super accessible and user-friendly, these files are easy to edit. Get the lowdown on their origins, uses and more.
PGM (Portable Grey Map) files store grayscale 2D images. Each pixel within the image contains only one or two bytes of information (8 or 16 bits). While that might not sound like a lot of information, PGM files can hold tens of thousands of shades — ranging from pure black to white and every shade of grey in between.
Even though PGMs are the standard for portable graphics, their small file size and colour limitations dinged their reputation and turned them into the “lowest common denominator” of image files. But there are still many great uses for this file type.
Developers created the PGM file format in the US in the late 1980s. Their hallmark is simplicity. PGMs contain a single image that’s both easy to write programmes for and to edit.
The file type uses a plain-text (ASCII) or binary file, containing information on width and height, whitespaces and a grey value. Rows divide the width and height and each space has a grayscale value — this is what creates the larger image.
Artists, designers and coding students regularly use PGM files for a variety of reasons.
People store and share beautiful photographs and art projects in PGM files. They’re ideal for creating a grainy, low-fi or abstract effect.
PGMs are one of the building blocks of computer programming. Many new and student programmers begin by studying PGM files and learning how to code, manipulate and use them in various situations.
PGMs are ideal for simple graphics and illustrations. You can use them in sets, pared-back in color and scale and stacked up in layers. They’re perfect for stark black and white symbols and graphics.
Discover more vector file types
Explore the advantages and disadvantages of using this file type.
Most image and text editing programmes can open PGM files on both Windows and Mac computers. You’ll first need to download a compatible programme.
While it’s possible to create PGM files with some photo-editing programmes, not all of them will allow that. While the files were once ubiquitous, JPEG files have gradually replaced them.
In most cases, users who want to create their own PGM files will need to download and use a dedicated software application or develop them through ASCII code.
PGM files are ideal for tasks like pasting into a Word document. You can easily adjust their dimensions, size and quality to fit your project.
Both image viewer and photo-editing programmes can convert PGM files into other types of photo files. Open the PGM file and then click Save As. Several options will be available.
In short: colour, quality and size. PGM files are extremely limited in how much information they can store for each pixel in the image. This also makes them smaller.
You can convert your PGM image to JPEG using Adobe Photoshop.
Learn about the JPEG, a standard file format that has stood the test of time.
Discover more about the proprietary file format for Adobe Photoshop.
Create beautiful vector art and illustrations.
7 days free, then €24,79/mo.