Skip to content
toolavix

CSS Box Shadow Generator

Design soft, layered and inset shadows with live preview and copy the CSS.

  • Free
  • No sign-up

Instant results, no sign-up required.

How does the CSS box-shadow property work?

The CSS box-shadow property draws one or more shadows around an element. Each shadow has a horizontal and vertical offset, a blur radius, a spread radius, a color and an optional inset keyword. This box shadow generator lets you adjust every value with sliders, stack several layers for realistic depth, preview the result on a box you can style and copy the finished CSS. It runs entirely in your browser.

How to create a CSS box shadow

  1. 1

    Pick a preset or start from the default shadow.

  2. 2

    Select a layer and move the offset, blur, spread and opacity sliders, and choose the shadow color.

  3. 3

    Add more layers for smooth, realistic shadows, or switch a layer to inset for an inner shadow.

  4. 4

    Adjust the preview colors and corner radius, then copy the CSS.

Key features

Multiple shadow layers

Stack up to six shadows. Layered shadows look more natural than a single large blur.

Inset shadows

Switch any layer to inset to create pressed buttons, inner glows and input field effects.

Live preview

See the shadow on a box with your own page and box colors and a custom border radius.

Clean CSS output

Copy a ready-to-use box-shadow declaration with rgba() colors, one layer per line.

Frequently asked questions

What do the box-shadow values mean?

The syntax is: offset-x offset-y blur-radius spread-radius color. Offsets move the shadow, blur softens its edge, spread grows or shrinks it, and the color sets its tint and opacity.

How do I make a soft, realistic shadow?

Use two or three layers with low opacity (5% to 15%), a small blur on the first and a larger blur and vertical offset on the next. Negative spread keeps the shadow tucked under the element.

What is an inset shadow?

An inset shadow is drawn inside the element’s border instead of outside it. It is used for pressed buttons, wells and inner glows.

Can I add multiple shadows to one element?

Yes. Separate shadows with commas in one box-shadow value. The first shadow is painted on top.

Does box-shadow affect layout?

No. Shadows do not take space or change the size of the element or its neighbors, and they do not receive pointer events.

More Developer tools

View all →