css box shadow generator

Design tools · Free CSS generator

CSS box shadow generator

Create a subtle card shadow or a bold layered effect. Adjust the settings, see the result instantly, and copy CSS ready for your stylesheet.

Combine up to five shadows for a softer, more natural result.

#0f172a

Live preview

Your next idea
Ready to customize.

Copy the declaration into the CSS rule for your card, button, image, or heading. Preview background is not included in the exported CSS.

How to use this box shadow CSS generator

Choose a preset or fine-tune horizontal offset, vertical offset, blur, spread, color, and opacity. Add layers for depth, use inset for an inner shadow, then copy the generated box-shadow declaration into your stylesheet.

What do the CSS box-shadow values mean?

The first two values move the shadow horizontally and vertically. Blur softens its edges, spread grows or shrinks it, and color with opacity controls its appearance. Negative offsets move the shadow left or up. An inset shadow appears inside the box.

Box shadow or CSS drop shadow: which should I use?

A box shadow follows the element’s box and rounded corners. A CSS drop shadow generator produces filter: drop-shadow(), which follows opaque pixels in shapes and transparent images. Drop shadows do not support spread or inset. This tool supports one drop shadow to avoid the different visual behavior of chained filters.

Can I use this as a CSS text shadow generator?

Yes. Choose Text shadow to generate text-shadow for headings and other text. Text shadows use horizontal offset, vertical offset, blur, and color; they do not support spread or inset. You can combine several text shadows.

How do I make a shadow look natural?

Start with low opacity, a small downward offset, and a soft blur. Try the Layered preset for a close shadow plus a wider, softer shadow. Check the result against the background you will use on your website.