🎨

CSS Shadow Generator

Build box-shadow and text-shadow CSS visually with multiple layers, live preview, and one-click copy.

Shadow Layers
4px
4px
12px
0px
25%
Preview
Preview
Generated CSS

Presets:

About CSS Box Shadow Generator

The CSS Box Shadow Generator lets you design box-shadow and text-shadow effects visually using sliders for offset X/Y, blur radius, spread, color, and opacity. You can stack multiple shadow layers to create complex, realistic depth effects and see the result live on an adjustable preview element before copying the CSS.

It's ideal for UI developers who want pixel-perfect shadows without trial-and-error in their code editor. All processing happens directly in your browser — no data is sent to any server.

Common Use Cases

How to Use

  1. Choose between box-shadow or text-shadow mode using the toggle at the top
  2. Click + Add Layer to add a shadow layer, then adjust the sliders for offset, blur, spread, color, and opacity
  3. Add additional layers for multi-shadow effects, or start from a named preset (Subtle, Glow, Layered, etc.)
  4. Click Copy CSS to copy the generated property value and paste it directly into your stylesheet

Frequently Asked Questions

Can I add more than one shadow to a single element?

Yes. CSS supports comma-separated shadow lists on both box-shadow and text-shadow. Use the + Add Layer button to stack as many layers as you need — the generator outputs all of them as a single valid CSS declaration.

What does the Spread Radius slider do?

Spread radius (only available on box-shadow, not text-shadow) expands or contracts the shadow before blur is applied. A positive value grows the shadow in all directions; a negative value shrinks it, which is useful for focused directional shadows.

What is an inset shadow and when should I use it?

The inset keyword moves the shadow inside the element's border, creating a recessed or pressed-in look. It's commonly used for form inputs to convey focus, for concave UI elements, or for active/pressed button states where the element should appear sunken.

Advertisement