Skip to content
Back to skills

Responsive Units

ASecurity

Use when reviewing stylesheets, component styles, and responsive behavior related to Use relative units for responsive layouts. Check the rendered layout across breakpoints and interaction states before proposing a fix.

  • 74,358 stars
  • 0 votes
  • 0 copies
  • 0 views
  • Added October 5, 2026
developmentgofrontend

Security analysis

A100/100

Pro scans all 2 files and shows the line behind each finding

Scanned October 5, 2026

npx -y skills add thedaviddias/Front-End-Checklist --skill responsive-units --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Responsive Units?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Responsive Units
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/thedaviddias-responsive-units/badge)](https://www.skillsdirectory.com/skills/thedaviddias-responsive-units)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: responsive-units
description: "Use when reviewing stylesheets, component styles, and responsive behavior related to Use relative units for responsive layouts. Check the rendered layout across breakpoints and interaction states before proposing a fix."
metadata:
  category: css
  priority: high
  difficulty: beginner
  estimatedTime: "20"
  source: frontendchecklist.io
  url: https://frontendchecklist.io/rules/css/responsive-units
---

# Use relative units for responsive layouts

Fixed pixel values override user browser preferences, making your site inaccessible to users who increase their default font size (a common accommodation for low vision). Relative units also reduce the number of breakpoints needed — elements naturally adapt to available space rather than requiring explicit overrides at every viewport width.

## Quick Reference

- Use rem for font sizes — it respects user browser font size preferences
- Use % or flex/grid for widths — they adapt to the parent container
- Use em for component-relative spacing (padding, border-radius)
- Use clamp() for fluid typography that scales smoothly between breakpoints

## Check

Find all px-based font-size, width, and padding values in this CSS file that should use relative units instead.

## Fix

Convert fixed px font sizes to rem equivalents and replace fixed widths with percentage or relative alternatives.

## Explain

Explain the difference between rem, em, %, vw, and vh, and when to use each one.

## Code Review

Review stylesheets, component styles, and responsive states related to Use relative units for responsive layouts. Flag exact selectors, declarations, or breakpoints that violate the rule in the rendered UI.

---

For full implementation details, code examples, and framework-specific guidance,
see `references/rule.md`.

Rule page: https://frontendchecklist.io/rules/css/responsive-units

Files in this skill

  • SKILL.md1.8 KB
  • references/rule.md3.3 KB

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments

Loading comments…