ATSvg

Choosing icon size: the trade-offs at 16 / 20 / 24 / 32

Search intent: Specification decision

Home › SVG guides › Choosing icon size: the trade-offs at 16 / 20 / 24 / 32

Icon size is not a matter of “looks about right”. A 1.5px stroke occupies nearly 10% of a 16px grid and only 5% of a 32px grid. Change the size and the stroke width, cap rounding and detail density all have to change with it, or the set ends up with some icons looking heavy and others light.

Contents

Choosing among the four common sizes

16px suits table rows, tags and dense admin screens — detail has to be minimal, and filled versions usually work better. 20px suits buttons and form prefixes. 24px is the general-purpose baseline for product interfaces, and most open-source icon libraries use 24 as their canvas. Only above 32px do duotone, gradients or decorative detail make sense.

Separate viewBox from displayed size

The viewBox is the internal coordinate grid (0 0 24 24); width / height or CSS decide the rendered size. Displaying a 24-grid icon at 16px works, but the stroke gets thinner. The correct approach is to use a library's native 16-grid version, or normalise stroke-width first and then scale the whole set.

<!-- 内部 24 网格,显示 24px -->
<svg viewBox="0 0 24 24" width="24" height="24" ...>
<!-- 同一文件显示 16px:线条视觉上会变细 -->
<svg viewBox="0 0 24 24" width="16" height="16" ...>

Hit area is not the same thing as icon size

A 16px icon does not mean a 16px button. Interactive targets should be at least 32–44px, achieved with padding while the SVG stays centred. This matters most on mobile: “hard to tap” is nearly always a target that is too small, not an icon that is drawn too small.

Mixing sizes on one page

Use one size per level of hierarchy. Navigation, list rows and buttons can each differ, but icons on the same row must match. If one item truly needs emphasis, use colour or a background — do not nudge it 2px larger, because that tiny difference reads as a misalignment rather than emphasis.

Icon size on responsive layouts

Responsive does not mean scaling icons by container percentage. Once a stroke lands on a fractional pixel the edge goes soft, and different stretch ratios make icons in one row look different weights. Instead, define a few breakpoints and switch to discrete size steps (20px on narrow screens, 24px on wide) while keeping the viewBox and stroke-width pairing intact. Dense table areas can drop one step, but never allow two sizes within one level.

FAQ

Why do some icons in one set look bigger than others?A circle or triangle has less visual area than a square inside the same bounding box, so it needs optical compensation (overshoot). Align by visual size, not by geometric dimensions.
Do I need separate exports for 2× screens?Not with SVG — the browser draws vectors at device resolution. Only PNG exports need 2× or 3× versions.

← All SVG guides · Licence and usage FAQ →

Related assets · 12 assets

Keep reading

All guides