Testing

CSS Grid Lanes: Browser Support, Features, Limitations

CSS Grid Lanes ships in Safari 26.4 and runs behind a flag in Chrome, Edge, Firefox, and Opera. Learn the features, use cases, and known issues.

Author

Prince Dewani

May 6, 2026

CSS Grid Lanes is a CSS Working Group layout mode that brings masonry and waterfall layouts to CSS Grid through display: grid-lanes. It ships fully on Safari 26.4 and iOS Safari 26.4, runs behind a flag on Chrome 140 to 150, Edge 140 to 147, Firefox 77 to 153, and earlier Safari 16.4, while Samsung Internet skips it.

This guide covers CSS Grid Lanes, the browsers that support it, the key features, the use cases, how to enable it with progressive enhancement, and the known issues.

What is CSS Grid Lanes?

CSS Grid Lanes is a CSS Working Group display mode that activates a masonry-style layout. The display: grid-lanes value reuses grid-template-columns and grid-template-rows so items pack into the lane that keeps content closest to the top. The CSS Working Group ships the spec inside CSS Grid Layout Level 3.

Which browsers does CSS Grid Lanes support?

CSS Grid Lanes is on by default only in Safari 26.4 and iOS Safari 26.4. Every other engine either runs it behind a flag or skips it.

Loading browser compatibility data...

CSS Grid Lanes compatibility in Chrome

Chrome runs CSS Grid Lanes behind a flag from Chrome 140 to Chrome 150 on Windows, macOS, Linux, ChromeOS, and Android. Enable the Experimental Web Platform features flag at chrome://flags to switch it on. Chrome 4 to Chrome 139 did not support the property at all. The Chromium team is updating the implementation to match the finalized grid-lanes syntax.

CSS Grid Lanes compatibility in Edge

Microsoft Edge follows Chromium and runs CSS Grid Lanes behind a flag from Edge 140 to Edge 147 on Windows, macOS, and Android. Toggle Experimental Web Platform features at edge://flags to switch it on. Edge 12 to Edge 139 did not support the property, and stable, unflagged Edge support has not landed yet.

CSS Grid Lanes compatibility in Firefox

Firefox runs an early masonry implementation behind the layout.css.grid-template-masonry-value.enabled flag from Firefox 77 to Firefox 153 on desktop and Android. Toggle the flag in about:config. Firefox 2 to Firefox 76 had no support. The current build still uses the older grid-template-rows: masonry syntax, and Mozilla is moving it to the display: grid-lanes value.

CSS Grid Lanes compatibility in Safari

Safari supports CSS Grid Lanes by default from Safari 26.4 on macOS and iOS Safari 26.4 on iPhone and iPad. Safari 16.4 to Safari 26.3 had it behind Develop > Feature Flags > Experimental Features. Safari 3.1 to Safari 16.3 did not support the property. iOS Safari follows the same version timeline since both rely on the same WebKit engine.

CSS Grid Lanes compatibility in Opera

Opera runs CSS Grid Lanes behind a flag from Opera 124 to Opera 125 on desktop. Opera 9 to Opera 123 had no support. Opera 127 and later regressed and currently do not support the property while the Chromium engine renames the masonry value to grid-lanes. Toggle the flag at opera://flags to enable it on the supported builds.

CSS Grid Lanes compatibility in Samsung Internet

Samsung Internet does not support CSS Grid Lanes on any version from Samsung Internet 4 to Samsung Internet 29. The browser tracks Chromium and is expected to inherit support once Chrome flips the flag on by default in a stable channel.

CSS Grid Lanes compatibility in Android Browser

The legacy Android Browser does not support CSS Grid Lanes. The stock browser stopped at Android 4.4 and never received any masonry layout work. Modern Android phones ship Chrome or Samsung Internet instead, and those engines control the support story.

CSS Grid Lanes compatibility in Internet Explorer

Internet Explorer 6 to Internet Explorer 11 do not support CSS Grid Lanes. Microsoft has retired the engine, so no future support is planned. Sites that still target IE 11 must fall back to a JavaScript masonry library or a flexbox column layout.

Note

Note: CSS Grid Lanes lands differently in Safari, Chrome, Edge, Firefox, and Opera. Test your masonry layouts on real browsers and OS with TestMu AI. Try TestMu AI free!

What are the key features of CSS Grid Lanes?

CSS Grid Lanes adds a single new display value plus one new property and reuses every other CSS Grid feature. The five points below cover what changes when you switch a container from display: grid to display: grid-lanes.

  • display: grid-lanes value: Activates the layout mode on a container. Every grid placement property still works on the children.
  • grid-template-columns for waterfall layouts: Defines vertical lanes. Items flow downward into the shortest lane, like a Pinterest board.
  • grid-template-rows for brick layouts: Defines horizontal lanes. Items flow rightward into the lane with the most free space.
  • flow-tolerance property: Controls how far an item can shift from source order to keep the lanes balanced. The default is 1em.
  • Explicit placement and item span: grid-column, grid-row, and grid-area still apply, so a hero card can span two lanes inside a grid-lanes container.

What are the use cases of CSS Grid Lanes?

CSS Grid Lanes targets layouts that mix items of different heights or widths inside a single container. The five use cases below pull from the WebKit and CSS Working Group examples and from production patterns that previously relied on a JavaScript masonry library.

  • Photo galleries with mixed aspect ratios: Tall portraits and wide landscapes fit into the same grid without cropping or letterboxing.
  • Pinterest-style boards: Cards of different content heights flow into the shortest lane, the layout pattern Pinterest, Unsplash, and Dribbble all use.
  • Newspaper and magazine layouts: A hero article spans two lanes while shorter pieces fill the rest, a pattern news sites previously hand-coded with floats.
  • Mega menu footers with variable groups: Site footers that hold link columns of different heights stay tightly packed without empty space at the bottom of short columns.
  • Museum and portfolio gallery walls: Curated grids of artworks, products, or case studies that vary in dimension stay aligned without manual sizing tweaks.
...

How do you enable CSS Grid Lanes with progressive enhancement?

CSS Grid Lanes ships unflagged only in Safari 26.4 and iOS Safari 26.4, so production code has to wrap the new value in an @supports query and fall back to display: grid for every other browser.

  • Set a display: grid baseline: Define grid-template-columns, gap, and any placement rules on the container. Every browser that supports CSS Grid renders this layout, which is the safe fallback.
  • Wrap the upgrade in @supports: Add @supports (display: grid-lanes) around a second rule on the same container. Browsers that parse the new value override the baseline; browsers that do not, ignore the block.
  • Switch display to grid-lanes inside the block: Set display: grid-lanes on the container. Reuse the same grid-template-columns and gap so the visual rhythm matches the fallback.
  • Tune flow-tolerance for source order: Drop flow-tolerance below 1em if your layout cares about reading order, like a news feed. Raise it above 1em for tighter packing where source order matters less.
  • Test the fallback in DevTools: Open DevTools, disable the @supports block, and confirm the plain Grid layout still renders cleanly. This is the layout your non-Safari users see today.
/* Progressive enhancement for CSS Grid Lanes. */
.gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(14rem, 1fr));
  gap: 1rem;
}

@supports (display: grid-lanes) {
  .gallery {
    display: grid-lanes;
    flow-tolerance: 1em;
  }
}

What are the known issues with CSS Grid Lanes?

CSS Grid Lanes is a young layout mode and the support gaps and quirks below catch teams that adopt it too aggressively.

  • Tab order vs source order mismatch: Items pack into the closest-to-top lane, so the visual order can drift far from the DOM order. Keyboard and screen reader users still follow source order, which can break perceived flow.
  • Opera regression on 127 and later: Opera 124 and 125 ran the older masonry value behind a flag, but Opera 127 dropped it while the Chromium engine renames the property. Plan for zero Opera coverage on current builds.
  • Firefox uses the legacy syntax: Firefox still parses grid-template-rows: masonry, not display: grid-lanes. A single stylesheet has to ship both forms until Mozilla updates the engine.
  • Cross-browser packing differences: In my experience, Safari, Chrome, and Firefox each apply slightly different flow-tolerance defaults, which means the same markup produces visibly different layouts during cross-browser QA. Always pin flow-tolerance explicitly.
  • Print and PDF rendering is undefined: The spec does not yet describe how lanes break across pages. Printing a grid-lanes container today produces inconsistent output, so use display: grid for any print stylesheet.
...

Citations

All CSS Grid Lanes version numbers, syntax notes, and platform behaviors in this guide come from these primary sources:

Author

Prince Dewani is a Community Contributor at TestMu AI, where he manages content strategies around software testing, QA, and test automation. He is certified in Selenium, Cypress, Playwright, Appium, Automation Testing, and KaneAI. Prince has also presented academic research at the international conference PBCON-01. He further specializes in on-page SEO, bridging marketing with core testing technologies. On LinkedIn, he is followed by 4,300+ QA engineers, developers, DevOps experts, tech leaders, and AI-focused practitioners in the global testing community.

Open in ChatGPT Icon

Open in ChatGPT

Open in Claude Icon

Open in Claude

Open in Perplexity Icon

Open in Perplexity

Open in Grok Icon

Open in Grok

Open in Gemini AI Icon

Open in Gemini AI

Copied to Clipboard!
...

3000+ Browsers. One Platform.

See exactly how your site performs everywhere.

Try it free
...

Write Tests in Plain English with KaneAI

Create, debug, and evolve tests using natural language.

Try for free

Frequently asked questions

Did you find this page helpful?

More Related Hubs

TestMu AI forEnterprise

Get access to solutions built on Enterprise
grade security, privacy, & compliance

  • Advanced access controls
  • Advanced data retention rules
  • Advanced Local Testing
  • Premium Support options
  • Early access to beta features
  • Private Slack Channel
  • Unlimited Manual Accessibility DevTools Tests