QR code design principles: colors, logos, and what affects scan rates
It’s surprising how often a seemingly minor design choice will ruin an otherwise perfect QR code. Whether you’re a marketer, a restaurant owner, or a nonprofit, the same rules apply: contrast, simplicity, and testing. In this post I’ll walk you through the core principles, give you a step-by-step workflow, and answer the most common questions people ask.
1. Choose the right color palette - keep it simple
Almost everyone knows the black-on-white standard, but many designers want to match a brand’s colors. The trick is to preserve the necessary contrast. A black module on a white background offers the maximum contrast ratio of 21:1 under WCAG, which is a guaranteed win. If you switch to a dark grey on a light grey background, the contrast ratio falls and the code becomes less robust in low light or on lower-end phones.
Step-by-step: measure the contrast with a free tool like WebAIM’s Contrast Checker. Enter the foreground and background colors you plan to use. If the result is below 4.5:1, adjust either the lightness of the background or the darkness of the modules. For a blue brand, you might use #0033CC for the modules and #FFFFFF for the background; that gives you a ratio of roughly 9:1, comfortably above the minimum and safe for scanners.
Remember, you can also invert the colors-white modules on a black background works too, especially for night-time prints. The key is consistency: don’t mix multiple dark shades or pastel backgrounds; the scanner’s algorithm struggles to differentiate subtle differences.
2. Size matters - module resolution and overall dimensions
QR codes are built from modules (the small squares). The resolution of each module is critical: if the modules are too small, a camera sensor will blur them, and the error-correcting algorithm will fail. The general rule of thumb is a module size of at least 0.3 mm (about 3 to 4 pixels on a 300 DPI print).
Practical step: set your code to a version that yields at least 21x21 modules for a simple URL. Multiply the module size by the number of modules to get the total square size. For example, 21 modules × 0.5 mm = 10.5 mm, which is about 0.42 inches. That’s the bare minimum for a smartphone to read reliably. If you’re printing on business cards, go for at least 2 cm (0.79 inch) to give a margin for scanning errors.
Don’t forget to add a safety margin around the code. A 4-module border, as recommended by the ISO standard, protects the code from cutting, smudging, or overlay by text. In practice, for a 2 cm code built from 21 modules, four modules work out to roughly 0.38 cm of white border on each side.
3. Logo placement - balance brand with readability
One of my favorite design tricks is to insert a logo into the center of a QR code. It’s a great branding opportunity, but it can backfire if not done right. The error correction of a QR code is what allows a code to still be read even if parts are obscured. There are four levels: Low (about 7%), Medium (about 15%), Quartile (about 25%), and High (about 30%). The default for most generators is Medium, which can recover up to about 15% of the code.
Step: measure your logo’s area relative to the whole code. If the logo occupies around 20% of the modules, you’ll want a higher error correction level such as Quartile or High. As a rule of thumb, keep the logo under about 30% of the total area. Add a clear white border of at least two modules around the logo to prevent it from touching the code’s dark squares.
For example, a small logo centered in a black-on-white code at Medium error correction will usually scan fine. Push the logo up toward half the code area, though, and older phones may start to fail. Switching to a higher error correction level and shrinking the logo is the usual fix.
4. Test across devices and lighting conditions
Even with perfect contrast and sizing, real-world conditions can derail a QR code. I recommend testing on at least three devices: an iPhone with a 12-MP camera, a Samsung Galaxy with a 48-MP camera, and a lower-end Android phone. Open the camera app, point it at the printed code, and record any errors or slow loads.
Lighting: test in bright daylight, indoor fluorescent light, and low-light (e.g., a lamp). In low light, scanners can struggle to detect the modules, especially if the background is slightly off. Adjust the contrast or increase the code size by 10-20% for outdoor use.
Software: if you can, use a QR scanning app or an online decoder such as the open-source ZXing decoder to confirm the code reads cleanly. For print media, ask a friend to scan from a distance of 2-3 meters to simulate a billboard or signage scenario.
5. Choose the right error correction level for your use case
Many designers default to Medium, but the level you pick should match your risk tolerance. A code printed on a windy billboard is more likely to get a smudge; use Quartile or High, the strongest level available. For a business card, Medium is usually enough.
Step: generate a few variants with Low, Medium, High, and Quartile error corrections. Print each at the same size, overlay a small watermark on the top left corner of each, then scan them. Observe which variant tolerates the watermark best. The one that still reads correctly is your optimal choice.
Tip: for very small codes, encode as little data as possible. A short URL keeps the QR version (and the number of modules) low, which makes each module larger at a given print size and easier for a camera to resolve.
6. Avoid gradients, patterns, and busy backgrounds in the surrounding area
A QR code is a self-contained visual cue; its surroundings should not distract the scanner. If you place a code on a patterned banner or a photo, the scanner may misinterpret background pixels as modules.
Practical instruction: always place the code on a solid white or light background. If you need a brand color, use a thin border of that color around the white background. Keep text within 1 inch of the code-any text too close can bleed into the code area and create noise.
Example: picture a charity event flyer that places a registration QR code directly on a pastel photo background. Attendees on older phones are the most likely to struggle, and dropping the code onto a crisp white panel instead is usually enough to clear up the failures.
7. Use a reliable generator that supports all the features you need
The last piece of the puzzle is the tool you use. Not all QR code generators are equal. Some only allow black-on-white, while others let you pick any color scheme. The generator on trulyfreeqr.com uses Medium (level M) error correction and lets you choose custom colors, frames, and shapes, and upload a logo without compromising the code integrity.
Step: create a QR code on trulyfreeqr.com with black modules, a white background, and no logo. Download the PNG (1100 × 1100 px) or the SVG, then check that the modules are crisp - the SVG is handy here because it scales to any print size without blurring. Use the same settings for all your printed materials to maintain consistency.
Frequently Asked Questions
- What is the ideal color contrast for a QR code?
- A black module on a white background is the most reliable combination. If you need a different color, make sure the contrast ratio is at least 4.5:1, following WCAG guidelines.
- Can I put a logo in the center of my QR code?
- Yes, but keep the logo no larger than 30% of the total QR area and leave a clear white border around it.
- How does print quality affect scan rates?
- Higher DPI, sharp edges, and no smudging are essential. Aim for 300 DPI at least when printing for consumer use.
- What is the minimum size for a QR code to be scannable?
- The smallest practical size is 1 inch square (25.4 mm) for most mobile devices, but for outdoor or long-range scans consider 2 inches or larger.
