In this article
A shadow tells people what sits above what. Soft and small reads as a card; large and wide reads as a dialog. Adjust any of these in the box shadow generator.

The four numbers
| Value | What it changes |
|---|---|
| Horizontal offset | Moves the shadow left or right |
| Vertical offset | Moves it up or down; light usually comes from above |
| Blur | Softens the edge |
| Spread | Grows or shrinks the shadow |
Resting card
box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
Enough to separate a card from a light background.
Hovered card
box-shadow: 0 16px 32px -4px rgba(0, 0, 0, 0.16);
A bigger vertical offset suggests the card has lifted.
Dropdown menu
box-shadow: 0 10px 24px -6px rgba(0, 0, 0, 0.18);
Dialog
box-shadow: 0 25px 50px -10px rgba(0, 0, 0, 0.35);
Pressed or inset field
box-shadow: inset 0 2px 6px rgba(0, 0, 0, 0.12);
Habits that keep shadows clean
Use one light direction across the page. Keep two or three levels, not a new shadow for every element. Prefer low opacity over dark grey. In dark themes, a lighter surface often separates layers better than a shadow.
Related generators
Try border radius, gradients and glassmorphism. Each can export CSS, SCSS, Tailwind or React style objects. For a whole interface, see website development.
Frequently asked questions
Short answers to what people ask us first. Need more? Send us a message.
Do shadows slow a page?
Static shadows are cheap. Animating large blurred shadows can cost more, so animate sparingly.
Can I stack shadows?
Yes. Separate them with commas; a tight shadow plus a soft one looks natural.
Free tools in this article
- Box Shadow GeneratorBuild layered, realistic CSS box shadows with blur, spread, opacity, color, and inset controls.
- Border Radius GeneratorVisually configure 8-value fancy CSS border radius with real-time box preview and one-click copy.
- CSS Gradient GeneratorCraft vibrant linear and radial CSS gradients with multi-color stops, angles, and preset palettes.
- Glassmorphism GeneratorGenerate modern frosted glass UI effects using CSS backdrop-filter, border opacity, and blur.
Written by Zoqonyx Team, the team at Zoqonyx. Last updated December 4, 2026.



