Flip PPM images online for free. Mirror horizontally or vertically.
PPM (Portable Pixmap) is the colour member of the Netpbm family invented by Jef Poskanzer — the PBM monochrome format dates to the mid-1980s, and PGM (greyscale) and PPM (colour) were added by the end of 1988. A PPM file is one of the simplest raster containers on disk: a magic number (P3 for ASCII, P6 for binary), width and height in decimal, a maxval (1–65535), then a left-to-right top-to-bottom stream of RGB triplets. That simplicity is exactly why PPM is still the de-facto interchange format inside graphics research, ray tracers, computer-vision toolchains, and anything built on the Netpbm utilities.
pamflip -lr / pamflip -tb step in a script — When you need a one-off flip but don't have Netpbm installed (Windows, locked-down enterprise machines), an online flip is faster than installing Cygwin / WSL just for one file.| Property | PPM (P6 / P3) | PGM (P5 / P2) | PBM (P4 / P1) | PAM (P7) |
|---|---|---|---|---|
| Channels | 3 (RGB) | 1 (grey) | 1 (1-bit B/W) | Arbitrary (RGBA, multispectral) |
| Maxval range | 1–65535 | 1–65535 | n/a (binary) | 1–65535 per sample |
| Bytes per pixel | 3 (≤255 maxval) or 6 | 1 or 2 | 1 bit | depends on tuple type |
| Compression | None | None | None | None |
| Magic numbers | P6 binary, P3 ASCII |
P5 / P2 |
P4 / P1 |
P7 |
| Typical use | Colour intermediate | Greyscale intermediate | B/W masks, faxes | Format with alpha |
| Convert to PNG | PPM to PNG | — | — | — |
| Setting | What it does | When to change it |
|---|---|---|
| "Horizontal" / "Vertical" | Mirrors the photo left-right or top-bottom; click again to undo | Selfie text, a logo facing the wrong way, an upside-down scan |
| "Save as" | "Same as original", or JPG, PNG, WebP, GIF, BMP, TIFF, ICO, AVIF, PSD, PPM | The destination needs another format |
| "Quality" (40–100, starts at 85) | Re-encode quality for JPG, WebP and AVIF output | Lower for smaller files, higher before more editing |
| Resize (same session) | Changes the pixel size along with the flip | Downscale for the web in one pass |
The editor has no DPI, bit-depth, compression-type or file-size-target setting. To hit a byte budget, run the result through Compress PPM.
Not for an ordinary 8-bit PPM (maxval 255). A flip is a pure pixel-grid rearrangement — the Netpbm pamflip manual describes left-right and top-bottom flips as coordinate transforms with no resampling, and the same applies here. The saved PPM is always a binary P6 with maxval 255, so a maxval-255 source keeps every RGB value exactly, while a source with a different maxval is rescaled to 0–255 (a higher one loses precision).
P3 is the ASCII variant — every R, G, and B sample is written as a decimal number separated by whitespace. P6 is the raw binary variant — samples are 1 byte (maxval ≤ 255) or 2 bytes big-endian (maxval ≥ 256). Both are accepted here, and the flipped file is always written as binary P6 — a P3 source comes back as P6. P6 is far more common because P3 files are typically 3–5× larger; if your toolchain needs ASCII P3, convert the result back with Netpbm (pnmtoplainpnm).
The PPM spec orders rows top-to-bottom, but plenty of render and capture pipelines emit rows bottom-up (the OpenGL framebuffer convention) and write them straight into a PPM header without flipping. Viewers that follow the spec render those files inverted. A vertical flip rewrites the row order to match the spec and the file opens correctly everywhere.
Horizontally. Heat-transfer paper, sublimation transfers, and most screen-printing positives need a left-to-right mirror so the design reads correctly once the paper is flipped onto fabric. Vertical flip is for upside-down captures, not for transfer mirroring.
Yes, in some cases. The output is always binary P6 with maxval 255 and 1-byte samples: a P6 file with maxval 255 comes back in the same form, a P3 file comes back as P6, and a file with a higher maxval (2-byte samples) comes back as 8-bit. The editor has no PPM variant or bit-depth setting.
Yes. The same editor has Resize, Crop and Rotate tabs next to Flip, so you can flip, then crop or turn the picture before one download (Crop PPM and Rotate PPM open the same editor on those tabs). Flips and 90° turns move pixels without resampling; a fine-angle rotation or a resize does resample.
pamflip from Netpbm?Functionally yes for the two flip axes. pamflip (which replaced pnmflip in Netpbm 10.13, December 2002) supports -leftright and -topbottom along with transpose and 90°/180°/270° rotations. This page's Flip tab handles the two flip axes; for rotations use the Rotate tab or Rotate PPM. If you need transpose (-xy) or diagonal reflection, pamflip on the command line is still the right tool.
If the file is going back into a Netpbm or graphics-research pipeline, keep it as PPM — that's what the format exists for, and an 8-bit flip is pixel-exact. If the file is destined for the web, email, or a phone, run PPM to PNG for lossless compression (typically 2–4× smaller for photographic content, 10×+ for line art) or PPM to JPG for photographs (often 10–20× smaller). A 1080p 24-bit PPM is roughly 6.2 MB on disk; the same image as PNG is usually 1–3 MB and as JPG 200–500 KB.
No. PPM with a maxval ≥ 256 stores each sample in 2 bytes, big-endian, but this editor works in 8 bits per channel: the file opens and flips, and it is saved as an 8-bit P6 (maxval 255), so the 48-bit-per-pixel colour depth is not kept. For HDR renders, scientific imagery, and 16-bit scans where 8-bit reduction would be visible as banding, use pamflip instead and keep the original.