CSS Box Shadow Generator

Create beautiful CSS box shadows visually. Add multiple shadow layers, tweak offsets, blur, spread, color and opacity, then copy the generated code. Everything runs in your browser.

Live Preview
Shadow Layers
Preview Options
Box Color
Background
Radius px
Size x px
-webkit- prefix
Import Existing CSS

Shadow Presets

How to Use CSS Box Shadows

The CSS box-shadow property adds shadow effects around an element's frame. You can set multiple shadows separated by commas. Each shadow is described by horizontal and vertical offsets, optional blur and spread radius, color, and an optional inset keyword.

Syntax

The full syntax is: box-shadow: [inset] offset-x offset-y [blur-radius] [spread-radius] color;. All offset, blur, and spread values are in pixels. The color can be any valid CSS color including rgba() for transparency.

Multiple Shadows

You can stack multiple shadows by separating them with commas. Shadows are rendered front to back — the first shadow sits on top. This technique lets you create complex, layered shadow effects like Material Design elevations or neumorphism.

Inset Shadows

Adding the inset keyword changes the shadow from an outer shadow (outset) to an inner shadow. Inset shadows appear inside the element's border, creating a pressed or recessed effect.

Features

Browser Support

box-shadow is supported in all modern browsers without vendor prefixes. If you need to support very old browsers (IE 9+), enable the -webkit- prefix option to include the prefixed version in the output.

Embed this tool on your site
<iframe src="https://devtoolbox.dedyn.io/tools/box-shadow" width="100%" height="700" frameborder="0"></iframe>

Frequently Asked Questions

What is CSS box-shadow?
CSS box-shadow adds shadow effects around an element's frame. It takes values for horizontal offset, vertical offset, blur radius, spread radius, and color. Multiple shadows can be applied to create complex depth effects like Material Design elevation.
What is neumorphism?
Neumorphism (or soft UI) is a design style that combines background colors with box shadows to create soft, extruded shapes. It uses two shadows — a light one and a dark one — to create the illusion of elements pushing out from the background.
Can I use multiple box shadows on one element?
Yes, CSS supports multiple box shadows separated by commas. This allows you to create complex effects like layered depth, inner glows combined with outer shadows, or realistic material shadows with multiple light sources.
Keyboard Shortcuts
Ctrl+Enter Run / Format
Ctrl+Shift+C Copy output
Ctrl+L Clear