Skip to content

How to Use the Magnetic Lasso Tool in Photoshop

The Magnetic Lasso tool in Photoshop draws a selection that snaps to the edge of an object as you trace around it. You click once on the edge, move the pointer along the outline, and the tool lays down a path that clings to the boundary between the object and its background, placing anchor points as it goes. It works best on subjects with a clear, high-contrast edge, such as a dark building against a pale sky or a product on a plain backdrop.

It sits in the same toolbar slot as the standard Lasso and the Polygonal Lasso. Press L to pick the lasso group and Shift+L to cycle through the three until the Magnetic Lasso, the icon with a small magnet, is active. You can also click and hold the lasso icon in the toolbar and choose it from the list.

How the Magnetic Lasso Finds an Edge

As you move the pointer, the tool looks at the pixels in a small zone around it and finds the place where brightness or color changes most sharply. That change is the edge, and the tool pins its path to it. Three settings in the options bar control how it searches: how wide a zone it looks in, how strong a change counts as an edge, and how often it places an anchor point. Getting those three right for the image in front of you is most of the skill.

Magnetic Lasso Settings Explained

Setting Range Default What it does
Width 1 to 256 pixels 10 px How far from the pointer the tool looks for an edge. Small values follow an edge closely; large values let you trace loosely.
Contrast 1% to 100% 10% How strong a change must be to count as an edge. High values pick only sharp, strong edges; low values also catch soft ones.
Frequency 0 to 100 57 How often anchor points are placed. Higher values put down more points and hold curves and corners better.
Feather 0 pixels and up 0 px Softens the edge of the finished selection. Usually better left at 0 and refined afterward.
Anti-alias On or off On Smooths the stair-step pixels along a curved selection edge. Leave it on for photos.

A useful starting point: on a crisp, high-contrast edge, use a wide Width (20 to 40 pixels) and a high Contrast so you can move quickly without the line wandering. On a soft or busy edge, drop the Width to 5 to 10 pixels, lower the Contrast, raise the Frequency, and trace slowly and closely. With a pressure-sensitive pen tablet, the pen pressure button in the options bar lets you press harder to shrink the width as you go.

How to Use the Magnetic Lasso Tool, Step by Step

  1. Zoom in. Work at 100% or closer so you can see the edge. Hold the Spacebar to pan the view while you trace, then release it to carry on.
  2. Set the options. Choose the selection mode in the options bar (new, add, subtract or intersect) and set Width, Contrast and Frequency for the edge you are tracing.
  3. Click once on the edge to place the first anchor point.
  4. Move the pointer along the edge. You do not need to hold the mouse button down. Keep the edge inside the width zone and move at an even pace.
  5. Click to add your own anchor points at sharp corners, or wherever the line starts to drift, to pin it in place.
  6. Back up when it goes wrong. Press Delete or Backspace to remove the last anchor point. Press it repeatedly to keep removing points until you reach a spot where the path was right.
  7. Close the selection. Move back over the starting point until a small circle appears next to the pointer and click. Or double-click, or press Enter, to close the shape with a magnetic segment from where you are to the start. Press Esc to cancel the whole thing.

Once closed, the outline turns into the familiar moving dashed line of an active selection.

Keyboard Shortcuts While Tracing

  • [ and ]: decrease or increase the Width by one pixel without stopping.
  • Caps Lock: shows the Width as a circle around the pointer, so you can see the zone the tool is searching.
  • Alt-click (Windows) or Option-click (Mac): draws a straight segment, as the Polygonal Lasso would. Useful across a stretch where the edge disappears.
  • Alt-drag or Option-drag: draws freehand, as the standard Lasso would.
  • Alt or Option double-click: closes the selection with a straight segment back to the start.
  • Delete or Backspace: removes the last anchor point.
  • Esc: cancels the selection in progress.

Cleaning Up the Selection

Few magnetic selections are perfect on the first pass. Fix the gaps with the same tool or any other selection tool:

  • Hold Shift and trace around a missed area to add it to the selection.
  • Hold Alt or Option and trace around an area that was included by mistake to subtract it.
  • Open Select and Mask from the options bar, or press Ctrl+Alt+R (Windows) or Cmd+Option+R (Mac), to smooth, feather, shift or decontaminate the edge with a live preview against a plain background.
  • Save a selection you worked hard on with Select > Save Selection, so you can reload it later.

Cutting a subject out to place it on a new background? How to replace the background of a photo in Photoshop takes a selection through to a finished composite.

What to Do With the Selection

A selection on its own changes nothing. Its value is in what you do next. The most flexible move is to click the Add Layer Mask button at the bottom of the Layers panel, which turns the selection into a mask: the selected area stays visible and the rest is hidden, and you can paint on the mask later to fix any edge without starting over. You can also add an adjustment layer while the selection is active, so a brightness or color change affects only the selected object. Press Ctrl+Shift+I (Windows) or Cmd+Shift+I (Mac) to invert the selection when you want to change the background instead of the subject, and Ctrl+D or Cmd+D to deselect.

New to masks, or want the other selection tools? Layers and masks in Photoshop explains how a mask hides and reveals parts of a layer without erasing anything, and how selections become masks.

When to Use a Different Tool

The Magnetic Lasso was built for one situation: a well-defined edge with strong contrast. Outside that, other tools do the job better.

  • Low-contrast edges, such as a gray cat on a gray sofa, give the tool nothing to hold. It wanders off into the background. Paint the selection with the Quick Selection tool or a brush on a mask instead.
  • Hair, fur and fine detail cannot be traced point by point. Make a rough selection, then refine the edge in Select and Mask, which is built for exactly this.
  • Whole people, animals or objects are often selected faster with the automatic Select Subject or Object Selection commands, then cleaned up by hand.
  • Hard, geometric product edges that must be perfectly smooth are better drawn with the Pen tool, which makes clean curves that you can edit point by point.
  • Straight-sided shapes, such as windows and doors, are quicker with the Polygonal Lasso.

Common Mistakes With the Magnetic Lasso

  • Moving too fast. The tool needs time to read the pixels. Speed through a corner and the path cuts across it.
  • Using one setting for the whole outline. Change the Width with the bracket keys as the edge changes, narrow where it is busy and wide where it is clean.
  • Starting over after one wrong turn. Press Delete to step back a few anchor points instead.
  • Feathering in the options bar. A feather set before you draw cannot be judged or changed afterward. Refine the edge in Select and Mask, where you can see the result.
  • Deleting pixels instead of masking. Pressing Delete on a selection removes those pixels for good. A layer mask does the same job and can be fixed later, which is the point of non-destructive editing.

Try This: A Five-Minute Magnetic Lasso Exercise

Open a photo of a single object against a plain background, such as a cup on a table or a building against the sky. Select it once with Width at 10 pixels, Contrast at 10% and Frequency at 57. Deselect, then select it again with Width at 30 pixels and Contrast at 50%. Compare how many corrections each pass needed. Then add a layer mask from the better selection and look at the edge at 200% to see where it needs refining.

Magnetic Lasso Tool FAQ

What does the magnetic lasso tool do in Photoshop?

It makes a selection that automatically snaps to the edge of an object as you trace around it. It finds the edge by looking for a sharp change in brightness or color near the pointer.

Why does the magnetic lasso keep jumping off the edge?

The contrast along that part of the edge is too low, or something with a stronger edge is inside the width zone. Lower the Width, click to place anchor points by hand through that stretch, or switch to a straight segment with Alt or Option.

How do I undo a point with the magnetic lasso?

Press Delete or Backspace while you are still tracing. Each press removes the most recent anchor point.

Is the magnetic lasso better than Quick Selection?

On a clean, high-contrast edge the Magnetic Lasso gives you precise control over the path. On most other subjects, Quick Selection or the automatic selection commands are faster, and many people use them first and refine afterward.