Home › Developer Tools › CSS Box Shadow Generator

CSS Box Shadow Generator

Build smooth, realistic shadows with sliders and copy the box-shadow CSS.

Shadow

CSS


    

How to use CSS Box Shadow Generator

  1. Adjust offset, blur, spread, colour and opacity, or pick a preset.
  2. Add more layers for softer, more realistic shadows.
  3. Change the background and box colour to test, then copy the CSS.

The values

ValueEffect
Horizontal / vertical offsetMoves the shadow right/down (negative: left/up).
BlurSoftens the edge. 0 is a hard shadow.
SpreadGrows or shrinks the shadow.
InsetPuts the shadow inside the box.

Layered shadows look real

Real shadows are sharp near the object and soft further away. Stacking two to five layers with growing blur and low opacity (try the Layered preset) gives that natural depth that single shadows can't.

Frequently asked questions

Does box-shadow slow pages down?

A few shadows are fine. Avoid animating large blurred shadows; animate opacity instead.

How do I make neumorphism?

Use the Neumorphic preset: a light and a dark shadow on a box the same colour as the background.

Can I use the code anywhere?

Yes, it is standard CSS.

Does it work in all browsers?

Yes, box-shadow works everywhere without prefixes.

Related tools

More Developer Tools