Driver FixRecommendedSound, Wi-Fi or graphics acting up? Check drivers firstFind missing or outdated drivers fast.Check DriversOctober DealsAmazon USOctober deal check: compare before you payAmazon US: current deals, useful picks and tech finds.Check DealsSlow PC?RecommendedPC slow today? Run a repair scan before it gets worseResolve common Windows issues and optimize system performance.Scan Now×
Skip to content
World desk3 min

CSS @supports: How to Check Browser Support

Use CSS @supports to test a feature before applying enhanced styles, with examples for declarations, selectors, alternatives and fallbacks.

What’s actually slowing this PC down?

Pick the symptom - the matching free tool is one click away.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Use CSS @supports to apply styles only when a browser accepts the CSS feature you test. Put a dependable fallback in ordinary CSS first, then add the enhanced styles inside a feature query. A successful query confirms that the browser accepts the tested syntax; it does not guarantee the feature works correctly in every situation.

Check support for a CSS property and value

A declaration query checks a specific property-value pair. Its basic syntax is a parenthesized declaration followed by a block of CSS:

.card {
  display: block;
}

@supports (display: grid) {
  .card-list {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
  }
}

The first rule is the baseline. Browsers that accept display: grid also receive the enhanced layout. Browsers that do not accept it ignore the query block and retain the baseline.

Test the exact value your design needs. A check that a browser accepts a property with one value does not prove it accepts a different, newer value of that property.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Combine requirements and alternatives

Require every feature with and

Use and when the enhanced style depends on all tested declarations being supported:

@supports (display: grid) and (gap: 1rem) {
  .card-list {
    display: grid;
    gap: 1rem;
  }
}

Accept any supported option with or

Use or when either declaration is sufficient, such as a standard or prefixed property:

@supports (text-stroke: 1px) or (-webkit-text-stroke: 1px) {
  .outlined-text {
    -webkit-text-stroke: 1px;
    text-stroke: 1px;
  }
}

Target browsers that fail a check with not

Use not for a special treatment when a condition is unsupported. Keep the ordinary baseline outside the query where possible, so it remains available to every browser:

@supports not (display: grid) {
  .card-list {
    /* Styles specifically for browsers without grid support */
  }
}

Use parentheses to group expressions when combining conditions. For the full syntax and examples, see the MDN reference for the @supports at-rule.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Check selector syntax instead of a declaration

To test whether a browser accepts a selector, use the selector() form rather than a property-value query:

@supports selector(:has(a)) {
  .card:has(a) {
    border-color: rebeccapurple;
  }
}

This checks whether the selector syntax is accepted. The MDN reference also documents feature queries for at-rules and font technology or format.

Choose a fallback that remains useful

  • Use a baseline first: write a layout or style that remains usable without the newer feature, then enhance it inside @supports.
  • Use a feature query when it changes the fallback decision: browsers generally ignore CSS they do not recognize, so every new declaration does not need a query.
  • Use @supports not (...) selectively: it can add a treatment for browsers missing a feature, but should not replace a sound baseline.
  • Test real behavior for high-impact features: a positive query means the browser accepts the tested syntax, not that its implementation is bug-free or complete.

MDN describes feature queries as a tool for progressively enhancing a site in its guide to using feature queries.

Check support from JavaScript

JavaScript can check CSS support conditions with CSS.supports(). It is useful when application logic needs to know whether a declaration or condition is accepted; for browser-version support details, consult the API’s dedicated compatibility information.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

Common mistakes and fixes

  • Testing the wrong value: check the exact property-value pair your styles rely on, not merely another value of the same property.
  • Checking a selector as if it were a declaration: use @supports selector(...) for selector syntax.
  • Expecting a positive result to prove correct rendering: feature queries test syntax support, not every behavioral detail. Verify the outcome in the browsers and devices that matter.
  • Putting the only usable style inside the query: move a functional baseline outside it, then place dependent enhancements inside.

Or skip the browser setup

If you need screenshots of pages in a browser without setting up your own capture flow, ScreenshotNeo provides a screenshot API and MCP server. For example, one GET request can capture a page as an image:

curl -G "https://api.screenshotneo.com/v1/shot" -d access_key=YOUR_API_KEY --data-urlencode url=https://stripe.com -o shot.webp

See the ScreenshotNeo API documentation for options. Cookie banners are accepted and removed before capture, along with supported newsletter popups and chat widgets; these cleanup steps can be turned off. Bot checks, blank pages, timeouts, failed loads and cache hits are not billed, and response headers report the page verdict and billing status. Its MCP server offers AI-agent tools for taking screenshots, getting page information and capturing PDFs. The free plan includes 1,000 screenshots per month with no card; paid plans start at $5 for 3,000.

Sign up free for 1,000 screenshots a month, with no card required.

Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Leave a Reply

Your email address will not be published. Required fields are marked *

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

More from the Wire

  1. Shenzhen desk3 min
    HONOR Expands Beyond Smartphones With Humanoid Robot RevealHONOR said it unveiled its first humanoid robot at MWC 2026 and named shopping assistance, workplace inspections, and supportive companionship as intended uses. Later Robotics D1 claims and a reported…
  2. Cupertino desk5 min
    Apple Unveils AirPods Max 2: The Upgrade That Should Have Happened Years AgoAirPods Max 2 adds H2-powered audio features and Apple claims up to 1.5× more effective ANC, but its design, Smart Case, and 20-hour battery rating are unchanged. Wired lossless audio…
  3. Cupertino desk4 min
    Apple’s OLED Touch MacBooks Are Coming—but the Dynamic Island Is the Real GambleApple has not announced an OLED touchscreen MacBook, but reports point to high-end models arriving in late 2026 or early 2027. The reported Mac Dynamic Island could be useful, but…
Recommended PC Tool
Recommended PC Tool
Crashes, No Sound, or Screen Glitches?Free driver scan
PC Slower Than It Used to Be?Free scan - under a minute

Two free Windows tools

One Free Minute Could Fix That PC

Before you go - each of these free tools takes about a minute and tackles what quietly slows a Windows PC down.

Special offer. View Outbyte info, uninstall instructions, EULA, and Privacy Policy.