Free Box Shadow Generator

Create layered CSS box shadows with a live preview — offset, blur, spread, colour, opacity and inset — and copy the code. Runs entirely in your browser.

Need a developer to build it?

Our developers turn designs into fast, clean and scalable websites and web apps.

01Overview

What is a CSS box shadow?

The CSS box-shadow property adds a shadow around an element such as a card, button, image or popup. Shadows create depth, separate content from the background and show which elements sit on top.

This free box shadow generator lets you adjust horizontal and vertical offset, blur, spread, colour, opacity and inset with sliders, and stack several shadows into one layered shadow for a softer, more realistic look. Copy the CSS when you are happy with the live preview.

Layered shadows are the secret behind the soft, premium look of many modern interfaces.

Quick answer

A CSS box shadow is written as box-shadow: x-offset y-offset blur spread colour; for example box-shadow: 0 10px 24px 0 rgba(0,0,0,0.25). Use the sliders above, add layers for softer depth, and copy the generated CSS.

  • Free, no sign-up
  • Layered shadows
  • Inset shadows
  • Copy CSS
02How to use

How to use the Box Shadow Generator

Start subtle. Most interfaces need far less shadow than you think.

  1. Set the offset

    X moves the shadow sideways, Y moves it down. A small positive Y looks natural.

  2. Adjust blur and spread

    Blur softens the edge. Spread grows or shrinks the shadow.

  3. Pick colour and opacity

    Low opacity, around 5% to 20%, looks most realistic.

  4. Layer and copy

    Add a second shadow for depth, then copy the CSS.

03How it works

CSS box-shadow syntax

Each shadow has up to five values. Separate layered shadows with commas.

Elevation from low to high
Low
Medium
High
Layered
Inset
box-shadow examplesbox-shadow: offset-x offset-y blur spread colour; box-shadow: 0 10px 24px 0 rgba(0,0,0,.25); /* Layered, soft */ box-shadow: 0 1px 2px rgba(0,0,0,.06), 0 8px 24px rgba(0,0,0,.08); box-shadow: inset 0 2px 4px rgba(0,0,0,.1);

Tinting the shadow with your brand colour, such as rgba(2,76,150,.08), often looks softer than pure black.

Worked example

A product card shadow.

Layer 1
0 1px 2px, 6% opacity
Layer 2
0 8px 24px, 8% opacity
Hover
0 12px 32px, 12% opacity
Effect
Card lifts on hover
Two light layers look softer and more natural than one heavy shadow.
04Reference

Shadow presets by elevation

Higher elements cast larger, softer shadows.

ElevationExample CSSUse for
Low0 1px 3px rgba(0,0,0,.1)Inputs, small cards
Medium0 6px 16px rgba(0,0,0,.1)Cards, dropdowns
High0 16px 40px rgba(0,0,0,.14)Modals, popovers
Insetinset 0 2px 4px rgba(0,0,0,.08)Pressed buttons, input fields
05Tips

Shadow design tips

Good shadows are felt rather than noticed.

Do this

  • Keep one light sourceAll shadows on a page should fall the same direction, usually down.
  • Use low opacityReal shadows are soft. Stay under about 20% opacity.
  • Layer for realismA small sharp shadow plus a large soft one mimics real lighting.
  • Animate on hoverA slightly bigger shadow on hover makes cards feel clickable.

Shadow mistakes to avoid

  • Hard black shadowsDark, sharp shadows look dated and heavy.
  • Inconsistent directionsShadows going different ways look broken.
  • Shadows on everythingIf every element floats, nothing stands out.
  • Heavy shadows on mobileLarge blurs on many elements can slow scrolling on low-end phones.
06FAQ

Frequently asked questions

How do I add a box shadow in CSS?

Use box-shadow with offset, blur, spread and colour values, such as box-shadow: 0 4px 12px rgba(0,0,0,.1).

What is an inset shadow?

A shadow drawn inside the element instead of outside, which makes it look pressed in.

Can I add multiple shadows?

Yes. Separate shadows with commas. The generator stacks them for you.

What is the difference between blur and spread?

Blur softens the shadow's edge. Spread makes the whole shadow larger or smaller before blurring.

How do I use box shadow in Elementor?

Most widgets have a Box Shadow control under Style or Advanced, or paste the CSS into Custom CSS.

Do box shadows affect performance?

Usually not. Very large blurs animated on many elements can affect scrolling on older phones.

The Big Growth team

Want a website that looks this polished?

We design and build fast, accessible, conversion-focused websites on WordPress and custom stacks. Explore our web development services.