Design 6 min read

Can QR Codes Be Colored? The Contrast Rules That Decide If They Scan

By Arvind Sharma Published 2026-11-29 Updated 2026-11-29
Arvind Sharma — Founder, QRPress QR Code GeneratorArvind built QRPress to give small businesses free, print-ready QR codes without scan caps, ads, or expiry. He writes guides focused on practical deployment — payments, printing, and shop-level security.

Yes, QR codes can be colored, but the colour is not the variable that matters. The scanner cares about the difference in luminance between the dark modules and the light background. A deep navy on white scans; a mid-grey on pale blue often does not, even though the two look equally colourful on a screen. This guide explains the contrast requirement, gives safe colour pairs, and shows how to check a brand palette before printing.

What the Standard Actually Requires

ISO/IEC 18004 defines the QR symbol. For print quality it specifies a minimum print contrast signal of about 0.6, which is roughly a 40% difference in luminance between the light and dark modules. In practice, designers use a luminance contrast ratio of at least 4:1 between foreground and background, and 7:1 or more for small codes or long viewing distances.

Luminance is not the same as hue. Two colours can look very different and still have almost the same luminance, which is why a red code on a green background can disappear to a camera. The ratio compares how much light each colour reflects, not how different they look to an eye.

The relationship also matters: dark modules must be darker than the background. An inverted code with light modules on a dark field can work on some phones and fails on others, because the finder patterns are designed to be detected as dark squares on a light field.

Safe Pairs and Risky Pairs

ForegroundBackgroundRough contrastVerdict
Black #000000White #FFFFFFAbout 21:1Best case
Deep navy #0B1F3AWhite #FFFFFFWell above 4:1Safe
Forest green #0F6E56Ivory #FEFFEFAbove 4:1Safe
Slate grey #6B7280White #FFFFFFAround 4.8:1Borderline; test
Mid grey #9CA3AFPale grey #F3F4F6Well below 4:1Will fail
White #FFFFFFBlack #000000InvertedAvoid

Treat the table as a starting point. The final check is a scanner, not a hex calculator, because print stock, varnish and screen brightness all change the effective contrast.

Avoid gradients, colour blends and textured fills behind the code. A gradient means part of the code has good contrast and another part does not, so the finder pattern may decode while the data region fails.

The Quiet Zone Is Part of the Colour Design

The four-module quiet zone around the code must have the same reflectance as the light modules. A pale brand tint in the margin is not a quiet zone; it is a decorative border that reduces the contrast at the edge where the scanner finds the code.

If the code sits on a coloured poster, give it a light rectangular patch with at least four modules of padding on every side. Make the patch part of the artwork, not something the print operator adds at the last minute.

This matters most when the code is printed on a dark or saturated surface. A white patch on a black package looks different from the brand, but it is the difference between a code that scans and a code that does not.

Logos, Dot Styles and Error Correction

A logo in the centre of the code consumes error correction capacity. Use level H (30%), keep the logo under about 20% of the code width, and give it a light border so its pixels do not merge with the data modules.

Rounded dots and stylised eyes are also a trade. They remove module area, which reduces the signal the scanner sees. Keep the shape close to a square, preserve at least most of each module, and test the styled version against the plain one before committing to a print run. The custom styling guide covers the safe limits.

Colour and error correction interact. If a brand colour is borderline on contrast, raising the error correction level will not rescue it; fix the colour first, then spend the remaining redundancy on styling.

Test on the Final Surface

  1. Generate the code in the final colours at final size.
  2. Print it on the actual stock, with the actual varnish or laminate.
  3. Scan with an iPhone camera, an Android camera and one budget phone.
  4. Scan in daylight and under warm shop lighting.
  5. Scan from the real distance and at a slight angle.

A code that passes on a glossy screen can fail on matte board, and the reverse. The only test that counts is the one on the finished material. The colour QR generator lets you export a proof quickly.

Frequently Asked Questions

Can QR codes be any colour?

No. The dark modules and the light background need a large luminance difference, at least about 4:1 in practice. Hue is irrelevant; a red-on-green code with similar brightness will fail.

Do inverted QR codes work?

Some phones decode them, many do not. The finder patterns are designed for dark modules on a light field, so keep that relationship and print a light patch behind the code if the background is dark.

What contrast ratio should I aim for?

At least 4:1 between foreground and background, and 7:1 or higher for small codes or long distances. ISO/IEC 18004 describes an equivalent print contrast requirement of about 0.6.

Can I use a gradient background?

Not safely. Part of the code will have good contrast and part will not. Use a solid light background and keep the four-module quiet zone clear.

Does a coloured logo in the centre reduce scannability?

It uses error correction capacity. Use level H, keep the logo under about 20% of the code width, and add a light border around it.

Create Your QR Code Instantly

Generate a coloured QR code and export a proof on your final background. Use our secure, no-registration static systems or spin up a dynamic tracker campaign in seconds.

Create Coloured QR Code