convert2image

Why colours shift when you convert an image

A common complaint: a photo looks rich and vivid on your phone, then after converting, uploading or opening on another computer it looks flatter, as if someone turned the saturation down a notch. Or a brand colour that was exactly right in the design file comes out slightly off on the website. Nothing seems to be broken. The numbers in the file might even be identical.

That last point is the clue. Colour in an image file is a set of numbers plus a set of instructions for interpreting them, and the instructions are easy to lose.

Numbers need a colour space

A pixel stored as red 255, green 0, blue 0 means “as red as possible”. But as red as possible on what? Different screens and standards can show different ranges of colour. The range and the exact meaning of the numbers is defined by a colour space.

The most common is sRGB, a standard from 1996 designed around typical monitors of the time. It is the default for the web and for most software. If an image says nothing about its colour space, everyone assumes sRGB.

Display P3 is wider, covering noticeably more saturated reds and greens. Recent iPhones, Macs and many Android phones capture and display photos in P3. Adobe RGB is another wide space, popular with photographers who print.

The same numbers mean different colours in different spaces. Red 255 in Display P3 is a deeper red than red 255 in sRGB.

ICC profiles are the instructions

An image states its colour space with an embedded ICC profile, a small block of data describing how its numbers map to real colours. Software that understands profiles uses it to translate the colours correctly for your screen.

Now the problem is clear. If a P3 photo loses its profile, through a careless converter, a metadata stripper that removes everything, or an upload system that ignores profiles, the numbers are read as sRGB. Every colour shifts towards the duller sRGB interpretation. Reds lose their punch, greens look slightly grey. The pixels did not change; the instructions went missing.

This is why a good metadata remover deliberately keeps the ICC profile while stripping camera and location data. Removing it would not improve privacy, but it would change how your photo looks.

Converting to sRGB on purpose

The safer route, if an image is going somewhere that might ignore profiles, is to convert its colours to sRGB properly before sending it. That remaps each colour to the nearest sRGB equivalent, so the result looks right even without a profile. The most saturated P3 colours cannot be represented exactly, so they are pulled in slightly, but the overall look is kept.

Browsers generally do this when they draw an image to a canvas, which is how in-browser converters work. So images converted on this site come out in sRGB, looking the way your browser displayed them. That is usually what you want for sharing and for the web.

CMYK: a different kind of shift

Printing uses cyan, magenta, yellow and black inks rather than light, and the range of colours ink on paper can produce is smaller than a screen's in some areas. Bright, glowing blues and greens on screen have no exact ink equivalent. When an RGB image is converted to CMYK for print, those colours get duller, and there is no avoiding it; the paper simply cannot reflect that colour.

The reverse trip also causes trouble. CMYK JPGs from print workflows sometimes look strangely dark or oversaturated in software that does not handle CMYK properly. If you receive files like that, ask for RGB versions for screen use.

HEX codes and small details

A HEX code such as #1E6FB4 is just the three RGB numbers written in base 16: 1E is 30, 6F is 111, B4 is 180. Converting between the two is simple arithmetic, and online colour pickers show both. What a HEX code does not include is the colour space. On the web it means sRGB, but the same code typed into a design tool working in P3 produces a slightly different colour. If a brand colour looks subtly different between a design file and a website, check what space each is using.

There is one more effect worth knowing. JPG stores colour at lower resolution than brightness, so small coloured details, like thin coloured text or a one-pixel coloured line, can come out paler and slightly blurred. That is a compression effect, not a colour space one, and the fix is to use PNG for that kind of image.

And sometimes it is the screen

Before blaming the file, rule out the display. Night modes, True Tone, adaptive brightness, battery savers and plain differences between screens all change how colours look. Two uncalibrated monitors side by side can disagree more than any file conversion. A quick check is to look at the original and the converted file on the same screen, at the same time.

What to do

  • For anything going on the web or to other people, work in and export sRGB.
  • Do not strip ICC profiles when cleaning metadata. Remove camera and location data, keep colour.
  • For print, ask the printer what they want, and expect bright screen colours to calm down on paper.
  • Compare original and converted files on the same screen before deciding something went wrong.