ToolNest logoToolNest.

Free CSS Box Shadow Generator

Last updated: October 12, 2026

Quick answer: The box-shadow property is six values and one headache: offsets, blur, spread, color, and inset/outset interact in ways that are nearly impossible to picture from numbers alone. This free CSS box shadow generator lets you see the shadow instead — drag the sliders for horizontal and vertical offset, blur, and spread, pick a color and opacity, toggle inset, and watch the preview update live. When it looks right, copy the clean CSS snippet straight into your stylesheet — or start from a preset (soft card, lifted, glow, hard shadow, inner) and tweak from there. Everything runs in your browser: no libraries, no signup, no waiting.

box-shadow: 10px 10px 25px 0px rgba(15, 23, 42, 0.25);

✓ Free forever  ·  ✓ No signup  ·  ✓ Tool inputs stay in your browser — never sent to our servers.

How to Use the CSS Box Shadow Generator

  1. Drag the sliders — horizontal/vertical offset, blur, spread — and watch the preview update live.
  2. Pick a shadow color and set its opacity; subtle dark shadows at 15–30% opacity look most natural.
  3. Toggle inset to push the shadow inside the box (great for pressed buttons and input fields).
  4. Switch the preview background to dark to check how the shadow reads on dark mode.
  5. Start from a preset if you're in a hurry, then tweak. Hit Copy CSS and paste the snippet into your stylesheet.

Why Use Our CSS Box Shadow Generator?

Common Use Cases

CSS Box Shadow Generator vs Alternatives

If you live in Chrome DevTools, its built-in shadow editor is already in your workflow — keep it. For everyone else, or when you want presets, dark-mode preview, and a clean snippet to paste into any project, this page is the fastest way from idea to CSS.

Frequently Asked Questions

What is the box-shadow syntax order?
box-shadow: offset-x offset-y blur-radius spread-radius color; — plus the optional inset keyword first for inner shadows. Only the two offsets are required; blur and spread default to 0. This generator writes the values in exactly that order.
What is the difference between blur and spread?
Blur softens the shadow's edge (higher = softer, more diffused). Spread grows or shrinks the shadow's size before blurring (positive = bigger, negative = smaller). A card shadow is usually high blur + zero spread; a glow is high blur + bright color.
What does inset do in box-shadow?
inset draws the shadow inside the element's border instead of outside — the classic 'pressed button' or sunken input look. Without it, the shadow falls outside the box (outset, the default). Toggle it on this page and watch the preview flip.
Can box-shadow have multiple shadows?
Yes — comma-separate them: box-shadow: 0 2px 4px rgba(0,0,0,.1), 0 8px 24px rgba(0,0,0,.12);. Layered shadows (a tight one + a soft one) look far more realistic than a single shadow. This generator builds one layer at a time — generate two and join them with a comma.
Does box-shadow hurt performance?
Large blurred shadows on many animated elements can cost GPU time, especially on low-end phones. For static cards and buttons it's negligible. If you're animating, prefer transform + opacity and keep the shadow static — or swap to filter: drop-shadow() only where you need the shadow to follow a non-rectangular shape.
box-shadow vs filter: drop-shadow — which should I use?
box-shadow follows the element's box (great for cards, buttons, modals). filter: drop-shadow() follows the rendered alpha shape — it wraps around transparent PNGs, SVG icons, and text. For UI panels, box-shadow (this tool) is the right call; for cutout images and icons, drop-shadow wins.