Inspector
Hover any element to see its size, spacing, font and colors in a card, with the box model drawn on the page in its real position. No panel to open and no tab to switch.
0% { transform: translateY(0) }100% { transform: translateY(-6px) }
Transitions (1)
background-colorTransitionduration0.2seasingease
Steps
- Press Alt+I. If the toolkit is already on, press 1 or click Inspector in the dock.
- Hover the element you want. A card shows its selector and size, and the margin and padding are drawn on the page.
- Press Space to pin the card. Pinned cards stay on the page, so you can compare several elements.
- Use ↑ and ↓ to move to the parent or the first child.
- Click an element to select it, then press O to see all its details in the side panel.
What the card shows
The card starts with the element's selector and the hint Space to pin, then up to four sections. A row only appears when it says something, so a plain element gives a short card.
| Section | Rows |
|---|---|
| Box Model | width, height, display, margin and padding (when they are not 0) and box-sizing |
| Appearance | border-radius, background-color and color, each color with a swatch |
| Text | font-family, font-size, font-weight, line-height, and letter-spacing or text-align when they are set |
| Accessibility | The contrast of the text against what is behind it, with its WCAG level |
The box model on the page
The element is drawn on the page in its real position: margin in orange, padding in green and the content box in blue, with a blue label above it that shows the selector and the size. You see spacing where it is, not as numbers in a panel.
Pinned cards
A pinned card stays where it is while you keep hovering other elements. Drag it by its handle to move it out of the way, and close it with its close button. Esc removes the last pinned card. Pinning works inside the screens of Responsive mode too.
Pause to reach menus and hover states
Press P to pause. The page becomes fully usable again, so you can open a dropdown, hover a button or start an animation. Press P again to resume and inspect what is now on the screen.
Clicking does not follow links
While the inspector is on, a click selects the element instead of following a link or submitting a form. Pause first if you need to click through.
Related
Last updated · Something wrong or missing? Tell us.