CSS scan Media Feature

Beginner
5 min read
Updated: Oct 2026
3 examples
Live preview

Definition and Usage

The scan media feature styles pages based on the device’s scanning process: progressive (full frame) or interlace (odd/even lines alternate).

Use it inside @media. Most modern screens are progressive. Interlace mattered more on CRT and some older TV signals—on those displays, slow motion and thicken fine details to reduce flicker.

Limited usefulness Often matches neither

Browsers may parse scan yet match neither progressive nor interlace on typical desktops. Keep solid defaults; do not rely on scan for critical layout.

Note Interlace tips

When targeting interlaced output, avoid very fast movement and keep animated details wider than 1px to reduce flickering.

CSS Syntax

syntax.css
@media (scan: progressive | interlace) { … }

Always wrap the feature in parentheses. Invalid forms like @media scan(progressive) do not work.

Feature Values

ValueDescriptionTry it
progressiveFull-frame rendering with no special line treatmentTry it
interlaceFrames alternate even and odd linesTry it

How to Use scan

Write defaults first, then enhance for a specific scan mode.

  1. Style the page for normal progressive screens by default.
  2. Add @media (scan: interlace) only when you need interlaced tweaks.
  3. On interlace: reduce animation speed and thicken fine lines.
  4. Optionally combine with a media type: @media screen and (scan: progressive).
PieceRequired?Role
@mediaYesWraps the media feature
scan keywordYesprogressive or interlace
Default stylesYesWork even when neither value matches
Media type (screen)OptionalNarrow the query further

Live Preview

You cannot switch scan mode in DevTools like a color scheme. This preview reports what matchMedia returns on this device and applies real @media (scan: …) styles when they match.

Detected scan queries

Gray means neither query matched. Blue / amber appear only when the matching media query applies.

Scan detection

Scan style sample

(scan: progressive) (scan: interlace)

Checking…

CSS Examples

Snippets stay focused on scan. View Output shows the intended look; on many desktops the real query may not match—use Try It Yourself to experiment.

Example 1 — Progressive Background

Enhance the page when progressive scanning is reported.

CSS
p {
  background: #e2e8f0;
}

@media (scan: progressive) {
  p {
    background: #dbeafe;
  }
}
Try It Yourself

How It Works

  1. Set a default. Gray background works everywhere.
  2. Add the query. @media (scan: progressive) wraps the enhancement.
  3. Change one thing. Blue background only when the feature matches.
  4. Expect gaps. If the browser matches neither value, you still see gray.

Example 2 — Interlace-Safe Motion

Slow animation and thicken a line when interlaced output is reported.

CSS
.box {
  border-bottom: 1px solid #334155;
  animation: slide 0.4s linear infinite;
}

@media (scan: interlace) {
  .box {
    border-bottom-width: 3px;
    animation-duration: 1.2s;
  }
}
Try It Yourself

How It Works

  1. Start normal. Thin border and faster animation for progressive screens.
  2. Detect interlace. The media query targets odd/even line scanning.
  3. Thicken details. 3px borders flicker less than 1px hairlines.
  4. Slow motion. Longer duration reduces combing and flicker.

Example 3 — Screen + Progressive

Combine a media type with the scan feature.

CSS
p {
  color: #334155;
}

@media screen and (scan: progressive) {
  p {
    color: #1d4ed8;
  }
}
Try It Yourself

How It Works

  1. Keep a default color. Slate text shows without the query.
  2. Add screen. Limits the rule to screen media (not print).
  3. AND the feature. and (scan: progressive) requires both conditions.
  4. Enhance only then. Blue text appears when both parts match.

Edge Cases & Pitfalls

Teach the syntax, then plan for “no match.”

match

Neither value may match

On many desktops, both queries fail. Defaults must already look correct.

syntax

Parentheses required

Use @media (scan: progressive). Forms like @media scan(progressive) are invalid.

interlace

Fine lines and fast motion flicker

On interlaced output, keep details thicker than 1px and avoid rapid movement.

scope

Not a width query

scan describes frame drawing, not viewport size. Pair width/height separately when needed.

motion

Also respect reduced motion

User preference for less motion still matters. Combine carefully with prefers-reduced-motion when you animate.

Browser Support

scan is a browser media feature. Node.js, Deno, and Bun do not evaluate it.

✓ Supported · Limited practical match

scan

Modern browsers parse the feature (Chrome/Edge 104+, Firefox 63+, Safari 16.4+). Matching a concrete value is uncommon on typical desktops—verify with matchMedia.

96% Parses the feature
Google Chrome 104+
Full
Mozilla Firefox 63+
Full
Apple Safari 16.4+
Full
Microsoft Edge 104+
Full
Opera 90+
Full
Samsung Internet 20+
Full
Internet Explorer No
None
@media (scan) Parsed; match uncommon

Bottom line: Safe to include as progressive enhancement. Never gate essential content on scan matching.

Key Takeaways

  • Role: detect progressive vs interlaced frame scanning.
  • Values: progressive and interlace inside @media (…).
  • Reality: many devices match neither—defaults first.
  • Tip: on interlace, slow motion and thicken lines over 1px.

One line: scan is a niche media feature—teach the syntax, enhance carefully, never depend on a match.

Frequently Asked Questions

It lets you apply styles based on how the output device draws frames: progressive (full frame) or interlace (alternating odd/even lines).
Two keywords: progressive and interlace. Write them inside @media, for example @media (scan: progressive) { … }.
Yes in the real world—modern monitors and phones are progressive. Interlace was common on CRT and some older TV signals.
Not always. Many desktop browsers parse the feature but match neither progressive nor interlace today. Treat scan as progressive enhancement, not a critical layout switch.
Mostly for TV, set-top, or legacy interlaced output: slow motion, thicken fine lines, and keep defaults solid without the query.
No. It is a CSS media feature evaluated by the browser layout engine, not a Node.js or server runtime feature.

Next: screen

Learn the CSS screen media type for display-targeted styles.

screen tutorial →

About the author

Mari Selvan M P
Mari Selvan M P 🔗

Developer, cloud engineer, and technical writer

  • Experience 12 years building web and cloud systems
  • Focus Full Stack Development, AWS, and Developer Education

I write practical tutorials so students and working developers can learn by doing—from databases and APIs to deployment on AWS.

8 people found this page helpful