TipClique
Menu

Cutting out hair in Photoshop

Cutting out hair

Cutting out hair in Photoshop starts ONE CLICK NOW and finishes CURRENT: press Select Subject in the Contextual Task Bar, which Adobe's Photoshop documentation states detects the subject including hair and other fine edges, then send that selection to Select and Mask and repair the 5 percent it got wrong with the Refine Edge Brush. The one click is genuinely good now and you should always start there, because it does in a moment what the channel method used to take 20 minutes to do. What it does not do is judge your particular picture, and hair is the operation where the picture decides everything: strands over a dark background come away cleanly, the same strands over foliage of a similar tone do not. This page is the repair work.

ONE CLICK NOW

Backlit hair against a bright background, the case an automatic selection loses.

How to select hair in Photoshop, step by step

To select hair in Photoshop, make the rough selection automatically and spend all of your effort on the boundary, which is where the whole job lives.

  1. Duplicate the layer with Ctrl+J (Cmd+J on macOS) so the original stays untouched underneath.
  2. Press Select Subject in the Contextual Task Bar, or use Select > Subject from the menu bar.
  3. Press Ctrl+Alt+R (Cmd+Option+R) to open the Select and Mask workspace.
  4. Set View to On Black for light hair, or On White for dark hair, and push Transparency to about 90%.
  5. Choose the Refine Edge Brush with R, and size it so the brush is roughly twice the width of the halo you are trying to recover.
  6. Paint one single pass along the flyaway strands, following the direction the hair grows, then release the mouse and look before painting again.
  7. Tick Decontaminate Colors and raise Amount to around 60%, which replaces the old background colour trapped in each semi transparent strand.
  8. Set Output To to New Layer with Layer Mask and press OK.

What goes wrong at step 6 is scrubbing. The Refine Edge Brush recalculates the whole area under the stroke each time you move, so a long scrubbing motion pulls background into the mask and eats the solid part of the head. Short strokes, released often, and Ctrl+Z the moment a stroke goes too far.

Edge Detection, and the radius that actually matters

Edge Detection is the slider that decides how wide a band of the picture Photoshop is allowed to reconsider, and setting it by feel is why most hair cutouts look wrong.

  • Set Radius to 1 px to 3 px for a tight ponytail or a short crop, where the edge is nearly solid.
  • Set Radius to 8 px to 15 px for loose curls, blown hair or fur, where strands cross open background.
  • Tick Smart Radius when one subject has both, such as a face with a hard jawline and a soft halo of frizz above it.
  • Leave Smooth at 0, because any value above 3 rounds individual strands into a blob.
  • Keep Feather under 0.5 px, since feathering is a blur applied equally to hair and to jaw, and it softens the one edge that should stay crisp.
  • Use Shift Edge at -5% to -15% to pull the mask in off a bright halo, and positive values only when the cutout has eaten into the subject.

The tell that this went wrong is visible at a glance and it is the thing this site keeps pointing at: a subject with a smooth, slightly glowing outline and no individual strands at all, which reads as cut out from 3 metres away. That silhouette dates a composite more reliably than any other single choice.

Removing the background around hair when the automatic selection loses

Removing the background around hair fails in 4 specific situations, and each has its own answer rather than a harder push on the same slider. The general case, where the automatic button is most of the answer, is Removing a background in Photoshop; what follows here is only the part where the picture defeats it.

  • Hair against a background of the same tone: build the selection from a channel instead. Open the Channels panel, pick the channel with the strongest contrast between hair and background, usually Blue for skin, duplicate it, then push it to black and white with Ctrl+L before loading it as a selection.
  • Hair against a busy scene such as leaves or brickwork: do not recover strands at all. Mask to a clean outline, then paint new hair on a layer above with a hair brush at 2 px to 4 px, following the original growth direction.
  • Hair carrying colour from the old background: tick Decontaminate Colors, and if that is not enough, add a Hue/Saturation adjustment clipped to the subject with Ctrl+Alt+G and drop saturation on the offending colour range only.
  • Blonde or white hair on a light background: invert your thinking and select the background instead with Select > Color Range, then press Ctrl+Shift+I. Detectors are trained on subjects, and a plain background is often the easier thing to describe.

Green screen backgrounds are the exception that looks like this problem and is not: the edge comes away easily and the difficulty is the green light spilled onto the hair itself. Removing a green screen covers that separately, because the fix is colour work rather than mask work.

Cutting out hair in Photoshop CS6 and other older versions

Cutting out hair in Photoshop CS6 uses Refine Edge, the dialog that Select and Mask later replaced, and the technique transfers almost line for line. CS6, released in 2012, has no Select Subject and no Contextual Task Bar, so make the first selection yourself with the Quick Selection Tool at W, then choose Select > Refine Edge. Inside it, Smart Radius, Shift Edge, Decontaminate Colors and Output To all behave as described above, and the tool called Refine Radius Tool is the same brush as the later Refine Edge Brush. In a current version you can still reach that older dialog by holding Shift as you choose Select > Select and Mask.

Photoshop Elements takes a third path again, keeping the Refine Edge style controls rather than the full workspace, while gaining the same one click Contextual Task Bar route. Removing a background in Elements sets out what that program does and does not have.

Checking the cutout before you commit

To check the cutout, put it against the 3 backgrounds that expose the 3 different failures, and do it before you build the rest of the composite.

  1. Add a solid black layer beneath and look for a pale halo, which means the mask sits 1 px to 2 px outside the true edge.
  2. Add a solid white layer beneath and look for a dark rim, which means the opposite and calls for a positive Shift Edge.
  3. Add a saturated red or magenta layer beneath and look for residual colour in the strands, which means Decontaminate Colors did not finish the job.
  4. Zoom to 100% and scroll the whole boundary, because a mask judged at 25% zoom always looks finished.
  5. Alt click the mask thumbnail to view the mask alone in black and white, then paint on it directly at 20% brush opacity to fix small errors without reopening the workspace.

Keep the layer mask rather than deleting the hidden pixels. A mask is editable in 6 months, a hard erase is not, and every operation this site treats as current is built on that same principle. Away from the desk, Photoshop on a phone makes the same first selection with Tap Select in its free tier, and then meets the one thing hair needs most: an edge inspected at 100%, which is slow work under a fingertip. Photoshop, operation by operation collects the rest of them.

Where to go next