Understanding Foreground vs Background
Foreground: The dark module colour — the actual data-bearing squares in the QR grid.
Background: The light colour behind the modules — can be white, off-white, or a light brand colour.
Both colours matter equally. A dark foreground on a dark background fails as surely as a light foreground on white.
Verified Safe Combinations
| Foreground Hex | Background Hex | Description | Contrast |
|---|---|---|---|
| #000000 | #FFFFFF | Classic black/white | 21:1 |
| #1A237E | #FFFFFF | Dark navy / white | 14.2:1 |
| #1B5E20 | #FFFFFF | Dark green / white | 11.6:1 |
| #B71C1C | #FFFFFF | Dark red / white | 7.8:1 |
| #4A148C | #FFFFFF | Deep purple / white | 10.2:1 |
| #000000 | #FFF9C4 | Black / pale yellow | 19.5:1 |
| #1A237E | #E8EAF6 | Dark navy / light lavender | 9.4:1 |
| #1B5E20 | #F1F8E9 | Dark green / pale green | 8.7:1 |
Combinations to Avoid
| Foreground | Background | Issue |
|---|---|---|
| Any mid-tone | Same mid-tone hue | Near-zero contrast |
| #FF6F00 (amber) | #FFFFFF | Only 3.0:1 — marginal |
| #FDD835 (yellow) | #FFFFFF | 1.7:1 — fails |
| #546E7A (blue-grey) | #ECEFF1 (near-white) | 3.6:1 — below threshold |
Background Colours Beyond White
Using a light brand colour as the background (instead of pure white) is safe as long as the foreground achieves 4:1+ contrast against it. Light backgrounds that work well:
- Off-white / ivory (#FFFFF0, #FAFAF5)
- Light grey (#F5F5F5, #EEEEEE)
- Pale blue (#E3F2FD)
- Pale yellow (#FFFDE7)
- Light cream (#FFF8E1)
Avoid light backgrounds with any saturation that could conflict with the foreground hue.
The Impact of Print Medium
The same digital colour combination can have different real-world contrast depending on print method:
- Laser print: Consistent colour reproduction, safe for verified combos
- Inkjet: Slight colour bleed — tested combinations may have marginally lower real-world contrast
- Screen print / fabric: Ink absorption can lighten dark colours — increase foreground darkness by 10–15%
- Foil/metallic: Reflective surfaces distort perceived contrast — avoid or add a matte coating
Putting this into practice
Start with the smallest real test you can run. Generate the code, print it at the exact size you plan to use, and scan it with two different phones in the lighting where it will live. Check that the destination page loads quickly on a mobile connection and that the call to action next to the code tells people what they will get. If anything feels slow or unclear, fix it before you print a full batch, because reprints cost more than a short test. Keep a note of the size, material, and placement that worked so the next batch starts from a proven setup.
Common mistakes to avoid
The most common mistakes are easy to avoid once you know them. Long payloads make modules tiny, low contrast makes edges hard to read, and text placed too close to the border eats the quiet zone the scanner needs. Covering a corner finder pattern with a logo or a sticker breaks detection entirely, and a code placed behind glare or on a curved surface fails even when the print is perfect. Review each of these points on a proof copy, and treat any failure as a reason to adjust the design rather than a reason to blame the scanner.
Quick checklist
- Keep the payload as short as practical so modules stay large.
- Keep dark modules on a light background with strong contrast.
- Leave a clear quiet zone on all four sides of the symbol.
- Test the printed code at the real viewing distance and lighting.
- Confirm the destination page loads fast on a phone.
- Recheck the code after any change to the link, design, or placement.
Related tools and guides
- Use the [QR size calculator](/qr-size-calculator) to match the printed size to the expected scan distance before you commit to a print run.
- Check print proofs with the [printed QR tester](/printed-qr-tester) so problems show up before a full run.
- The [QR placement guide](/qr-placement-guide) covers height, lighting, glare, and surfaces that affect scan success.
- Test every code with the [QR scanner](/qr-scanner) on more than one phone before you publish or print it.
- When a one-dimensional symbol fits better, the [barcode generator](/barcode-generator) covers retail and inventory formats.
- The [blog](/blog) collects more guides on sizing, printing, security, and payments for QR codes.