01What is Box Shadow Generator?
Box Shadow Generator builds one CSS box-shadow with sliders and draws it on a sample card while you drag. It's for the moment when you know roughly what you want, a soft lift or a crisp ring, but don't want to tweak numbers in DevTools ten times. The controls map straight onto the box-shadow syntax in the W3C CSS Backgrounds and Borders Level 3 spec. X Offset and Y Offset move the shadow from -50px to 50px. Blur runs from 0 to 100px and controls softness. Spread runs from -50px to 50px and grows or shrinks the shadow before it's blurred. The Color picker sets the hue, and a separate Opacity slider sets the alpha. Tick Inset to move the shadow inside the box. The tool turns your hex color into an rgba() value with two decimal places. So #3b82f6 at 50% becomes rgba(59, 130, 246, 0.50). It always writes all four lengths, including a 0px spread, so the output is explicit and easy to edit later. With Inset ticked, the inset keyword goes first. The result is one unprefixed declaration, because current browsers support box-shadow without -webkit-. A worked example. Set X Offset to -8, Y Offset to 12, Blur to 30 and Spread to -6, then pick #1e293b at 40%. You get box-shadow: -8px 12px 30px -6px rgba(30, 41, 59, 0.40);. The negative spread pulls the shadow in first, so the blur falls mostly below the card instead of fogging every side. Some limits to keep in mind. You get one shadow layer at a time. Layered shadows need you to generate each one and join them with commas yourself. Values move in whole pixels only. The color picker has no alpha channel of its own, which is why opacity is a separate slider. Reset brings back the 4px 4px 10px black shadow at 25% opacity with Inset off. The shadow is computed in the page from your slider values. None of those values leave your machine, and Copy just writes the finished line to your clipboard.
UI developers who need exact offset, blur, spread and alpha values for a single shadow, such as an elevation or focus-ring token. The tool runs entirely in your browser, so your data never leaves your device.
02How to use Box Shadow Generator
- Drag the X Offset and Y Offset sliders to move the shadow
- Set Blur for softness and Spread to grow or shrink the shadow
- Pick a color and set Opacity
- Tick Inset for an inner shadow
- Copy the box-shadow line from the CSS panel
03Worked examples
- Input:
X Offset 4, Y Offset 4, Blur 10, Spread 0, Color #000000, Opacity 25% (defaults) - Result:
box-shadow: 4px 4px 10px 0px rgba(0, 0, 0, 0.25); - Input:
X Offset 0, Y Offset 0, Blur 0, Spread 3, Color #3b82f6, Opacity 50% - Result:
box-shadow: 0px 0px 0px 3px rgba(59, 130, 246, 0.50); - With no offset and no blur, the spread alone draws a solid 3px ring around the box, a common focus-ring style.
- Input:
X Offset 0, Y Offset 2, Blur 4, Spread 0, Color #000000, Opacity 15%, Inset checked - Result:
box-shadow: inset 0px 2px 4px 0px rgba(0, 0, 0, 0.15); - Inset draws the shadow inside the top edge, which makes the element look pressed in.
- Input:
X Offset -8, Y Offset 12, Blur 30, Spread -6, Color #1e293b, Opacity 40% - Result:
box-shadow: -8px 12px 30px -6px rgba(30, 41, 59, 0.40); - A negative spread shrinks the shadow before it is blurred, so a large blur doesn't spill out wide on every side.
- Input:
X Offset 6, Y Offset 6, Blur 0, Spread 0, Color #111827, Opacity 100% - Result:
box-shadow: 6px 6px 0px 0px rgba(17, 24, 39, 1.00); - Zero blur at full opacity gives a hard, solid offset shadow.
04Common use cases
- Creating a subtle elevation shadow for a card, popover or dropdown menu
- Making an inset shadow for a pressed button or a recessed text input
- Drawing a focus ring with spread and zero blur that doesn't move surrounding content
- Using negative spread so a large blur stays under an element instead of spilling out the sides
- Getting exact pixel and alpha values for a shadow token in a design system
- Building a hard, zero-blur offset shadow for a neo-brutalist button
05Tips
- For more natural depth, stack two shadows in one property: a small tight one plus a large soft one, e.g. box-shadow: 0 1px 2px rgba(0,0,0,0.12), 0 8px 24px rgba(0,0,0,0.12)
- A low-opacity black (around 10 to 25%) usually beats a solid gray, because it darkens whatever color is underneath
- Spread with 0 blur and 0 offset (0 0 0 3px) is a common focus-ring trick that doesn't shift layout
- For PNG icons or other irregular shapes, filter: drop-shadow() follows the visible pixels, while box-shadow follows the box
06Related concepts
CSS elevation, Material Design, Neumorphism, filter: drop-shadow.
Frequently Asked Questions
What is Box Shadow Generator?
Box Shadow Generator is a free, browser-based developer tool on AIDToolStack. Visual CSS box-shadow editor with multiple shadows, live preview, and CSS output. It requires no installation or sign-up and works entirely in your browser.
Is Box Shadow Generator free to use?
Yes. No sign-up, no fees and no usage cap.
Does Box Shadow Generator store my data?
No. It runs in your browser; nothing is uploaded.