Take Mac window screenshots without the shadow
· 6 min read
Press Command-Shift-4, then Space, then hold Option while you click the window. The capture arrives with no drop shadow and no transparent margin around it. If you never want the shadow, one defaults write line removes it from every window capture until you change it back.
Why the shadow is a problem
Capture a window the normal way and macOS does not photograph the pixels of that window alone. It renders the window plus the soft shadow macOS draws underneath it, then saves the result as a PNG with an alpha channel, with roughly fifty to a hundred transparent pixels of margin on each side.
That looks fine on a web page with a pale background. It causes three specific problems everywhere else:
Alignment. Drop a shadowed capture into a document or a slide and the visible window sits inside a larger invisible rectangle. Two captures placed side by side will not line up on their edges, and centering one looks off by a few pixels.
Background clashes. The shadow is dark and semi-transparent. Over a dark slide or a dark documentation theme, it turns into a visible gray halo instead of a soft edge.
File size and dimensions. A window that is 900 pixels wide produces an image well over 1000 pixels wide, at Retina scale twice that again. When a documentation tool or a support form has a size limit, the shadow is paying for nothing.
None of this is a bug. It is a deliberate design choice from an era when screenshots mostly appeared on pale backgrounds, and it is one modifier key away from being optional.
The one-off: hold Option
This is the method to learn, because it needs no setup and no undoing.
- Press Command-Shift-4. The pointer turns into a crosshair.
- Press the Space bar. The pointer becomes a camera icon and the window under it highlights.
- Move over the window you want. Menus, palettes, the Dock and the menu bar all highlight individually and can all be captured this way.
- Hold Option and click.
The capture is saved with the window’s own edges and nothing else. Release the Option key too early and you get the shadow back, so hold it through the click.
If the window is already tightly framed on screen you may prefer Command-Shift-4 and a manual drag, but the window mode is better than dragging: it gets the rounded corners exactly right and includes the full title bar without you aiming.
Turn it off for good
If you take window captures often, the preference is worth setting so you stop thinking about the modifier key.
- Open Terminal (Applications, Utilities).
- Paste this and press Return:
defaults write com.apple.screencapture disable-shadow -bool true; killall SystemUIServer
killall SystemUIServer restarts the process that handles the menu bar so the new value takes effect immediately. The menu bar flickers once and nothing else is disturbed.
Every window capture from then on comes without the shadow, including ones taken from the Command-Shift-5 toolbar with Capture Selected Window, and the clipboard versions taken with Control held.
To put the shadow back, remove the key rather than setting it to false, so the value returns to whatever a fresh Mac does:
defaults delete com.apple.screencapture disable-shadow; killall SystemUIServer
If Terminal reports that the domain or default pair does not exist, the key was never set and the shadow is already at its default.
With the preference on, the Option key reverses: hold it while clicking to get a capture with the shadow for the one time you want it.
Removing a shadow you already captured
For screenshots you took before you knew about any of this, cropping is quicker than retaking, as long as you do not need the corners perfect.
- Open the image in Preview.
- Press Command-A to select all, or drag a rectangle just inside the window edges with the selection tool.
- Press Command-K to crop.
- Save with Command-S.
The awkward part is the rounded corners: cropping to a rectangle leaves a small wedge of shadow at each corner. If the image is going onto a white page, nobody will see it. If it is going onto a dark one, retaking the capture with Option held is faster than fighting it.
Preview’s Instant Alpha tool is aimed at removing a solid background color and does not deal well with a soft shadow gradient. Do not spend twenty minutes on it.
What the shadow setting does not cover
Worth being clear about the limits, because the preference has a narrower reach than its name suggests.
- Full-screen captures (Command-Shift-3) never had a shadow. Nothing changes.
- Region captures (Command-Shift-4 and drag) never had one either. If a shadow appears in one, it is the shadow of a window you dragged across, captured as part of the screen.
- Screen recordings are unaffected.
- Window shadows still appear on screen. This is only about what gets saved.
The other two screenshot settings people change at the same time live elsewhere: where the files are saved, which is in the Command-Shift-5 Options menu, and the floating preview that hovers after each capture, which is in the same menu and also delays the file being written.
Setting all three without Terminal
Mainspring (https://trymainspring.com/) lists screenshot without shadow as a power-up, next to the custom screenshot folder and the floating thumbnail, and groups them into a Screenshot Studio recipe you apply as a set and revert as a set. Each power-up is a real macOS setting with a plain-English label; the previous value is recorded before anything changes, so one click undoes it. It is $29 once for up to three Macs, with a one-day trial that includes everything and needs no account.
It does nothing the command above does not, which is the honest way to describe it. If Option-click covers your needs, use Option-click. The reason to add an app is a machine you are setting up properly, where you want the Finder, Dock and screenshot changes made in one pass and reversible later, without keeping a page of commands in a note.
Questions
Does Option-click work in the Command-Shift-5 toolbar too?
Choose Capture Selected Window, then hold Option as you click the window. The behavior matches Command-Shift-4 with Space, and the disable-shadow preference governs both, so setting it once covers whichever route you use.
My capture has no shadow but still has a transparent margin. Check the corners. A window capture is transparent outside its rounded corners by design, even without a shadow. That is a few pixels, not the wide margin the shadow adds, and it is what lets the rounded corners sit cleanly on any background.
Can I keep a shadow but make it smaller or lighter? No. It is on or off; the shadow itself is drawn by the window system and is not adjustable. If you want a specific shadow in a document, capture without one and add the effect in whatever tool is laying the page out, where you can control it.
Will this survive a macOS update? Preferences in your home folder normally do. If shadows return after an upgrade, run the command again. It is one line and takes a few seconds, which is a reasonable reason to keep it in a setup note alongside the screenshot folder command.