bookmarklet.one

CSS Grid Overlay Bookmarklet

Show CSS grid tracks and flexbox containers on any page, plus an adjustable 12-column layout grid for checking alignment. Free bookmarklet, no extension.

CSS Grid Overlay
← Drag this button to your bookmarks bar.Click it here to try it on this page first.

On a phone? Use Copy code, then save it as a bookmark's URL — step-by-step guide.

Web Dev CSS DesignUpdated 2026-11-27Free · No extension · Runs locally

CSS Grid Overlay makes page layout visible. It finds every element with display: grid or display: flex, outlines it, and draws the real column and row tracks of each grid container using the sizes the browser computed, including gaps. Flex containers get a dashed outline labeled with their direction.

On top of that you can switch on a classic design column grid: choose the number of columns, the gutter and the maximum content width, and check whether the page's content lines up with the layout your designer intended. It is the quickest way to answer "is this a 12-column grid?" or "why is this card 3 pixels off?".

The panel lists each grid container with its selector and track sizes; click one to scroll to it. The overlay follows scrolling and resizing, and everything disappears when you close the panel or run the bookmarklet again.

What it does

  • Outlines all CSS grid containers and draws their computed column and row tracks
  • Outlines flex containers with a dashed border and a row/column label
  • Optional design column grid with adjustable columns, gutter and max width
  • Panel lists each grid with its selector, track count and sizes; click to scroll to it
  • Overlay updates on scroll and resize, and is removed completely when you close it

How to install the CSS Grid Overlay bookmarklet

  1. Show your bookmarks bar. Press Ctrl+Shift+B on Windows/Linux or Cmd+Shift+B on a Mac (Chrome, Edge, Brave, Firefox). In Safari choose View › Show Favorites Bar.
  2. Drag the blue button above onto the bar. That's it — the bookmark now holds the code.
  3. Open any website and click the bookmark to run it on that page. Click it again to close it.

Can't drag (phone, tablet, locked-down browser)? Copy the code below, create any bookmark, then edit it and paste the code as its URL. See how to add a bookmarklet in every browser.

How to use it

  1. Click CSS Grid Overlay in your bookmarks bar.
  2. Use the checkboxes to show or hide grid tracks, flex outlines and the column grid.
  3. Adjust columns, gutter and max width to match your design system (12 / 24 px / 1200 px by default).
  4. Click a grid in the list to scroll to it; run the bookmarklet again or press Esc to remove everything.

Reading the overlay

Pink bands are the column tracks of a CSS grid and dashed pink lines are row boundaries; the space between bands is the gap. Track sizes come from the computed grid-template-columns, so 1fr and repeat() are already resolved to pixels. Implicit tracks created by auto-placement are included because the browser reports them too. Blue dashed boxes are flex containers. If the design column grid does not line up, check the container padding first: many layouts center a max-width wrapper and the padding shifts the first column.

Bookmarklet code

This is the exact code inside the button above (8,768 characters). It runs only in your browser and sends nothing to us. Paste it into the Bookmarklet Decoder to read it formatted.

Frequently asked questions

Does it work with Tailwind or Bootstrap grids?

Yes. Tailwind grid utilities create real CSS grids; Bootstrap rows are flex containers and get a flex outline. The column grid lets you compare against a 12-column layout.

Why are some grids not drawn?

Only grids in the visible part of the page are drawn, up to 60 at a time. Scroll and the overlay updates.

Does it change the page layout?

No. The overlay sits on top in its own layer and ignores the mouse, so the page stays clickable.

Related bookmarklets

Outline every element on a page with a color based on its nesting depth to spot overflow, stray margins and layout bugs…

Show the live viewport width and height, device pixel ratio and the current Tailwind, Bootstrap and page CSS breakpoint…

Hover any element to see its tag, ID and CSS classes, then click to copy a unique CSS selector. A free bookmarklet for…

Count DOM elements, nodes and nesting depth on any page, with a sortable per-tag table and Lighthouse DOM-size…