How to arrange desktop icons on a Mac so they stay where you put them

Icons were dragged into neat columns on the right edge. A week later they are a loose cloud in the middle, or they snapped back into one alphabetical line down the left side, or half of them jumped after a monitor was unplugged. Nothing was touched on purpose, so the arrangement feels like something macOS keeps undoing on its own.

It is not random. The desktop has three different layout modes, only one of which lets a person decide where a file sits, and switching between them silently throws away the positions from the previous mode. Once the mode is set on purpose, positions hold. The rest of the drift comes from a small number of specific events, and each has a tell.

The desktop is a Finder window in icon view

Everything that applies to a folder shown as icons applies to the desktop, because the desktop is that folder drawn without a window frame. That is why the layout controls live in the Finder's own menus rather than in System Settings.

Control-click any empty part of the desktop and the menu that appears carries the whole toolbox: Clean Up, Clean Up By, Sort By, Show View Options, and Use Stacks. Apple's own page for icon view describes the first three in the order most people need them.

Quickly realign icons: Choose Clean Up. If you don't see Clean Up, it's because you set your icons to be sorted automatically or you're using Stacks to automatically sort your files. To see Clean Up, either choose Sort By > None or verify that there isn't a checkmark next to Use Stacks. Source: support.apple.com, read September 23, 2026

That paragraph is the whole puzzle in miniature. Clean Up is a one time nudge that pushes loose icons onto the grid. It only exists when nothing else is already deciding placement. If Clean Up is missing from the menu, the Mac is in automatic mode and manual placement is being overruled by design.

Positions themselves are stored next to the files. Each folder viewed as icons gets a hidden index file named .DS_Store, and the desktop's copy sits at ~/Desktop/.DS_Store. It holds icon coordinates, the view mode, the icon size and the sort setting for that folder. This matters later: one folder, one file, one set of coordinates.

The three modes, and what each one costs

Choosing a mode is the actual decision. Everything else is trim.

Mode Who decides where an icon sits New files land Clean Up available
Sort By > None, free placement The person dragging Wherever there is a free grid cell Yes
Sort By > Name, Kind, Date and so on macOS, continuously Inserted in sort order, pushing others along No
Use Stacks macOS, by group Absorbed into the matching pile No

Free placement is the only mode where a deliberate arrangement survives. Work in progress on the left, reference material top right, a screenshot dumping ground at the bottom: none of that is expressible as a sort rule, so a sort rule will destroy it.

Automatic sorting is the right answer for a desktop treated as a queue rather than a workspace. Sort By Date Added keeps the newest arrival in a predictable corner, which beats hunting for a file whose name nobody remembers. The price is that every new file shifts everything after it.

Stacks sits further along the same line. Turn it on with View > Use Stacks or Control-Command-0, and files collapse into piles grouped by kind, by date or by Finder tag.

You can group stacks by kind (such as images or PDFs), date (such as the date a file was last opened or created), or Finder tags. Source: support.apple.com, read September 23, 2026

Stacks makes a crowded desktop look calm in one keystroke, and it makes individual placement meaningless, since a file is wherever its group is. Switching Stacks off restores the loose icons, but not necessarily to the coordinates they had before.

Set free placement deliberately, then shape the grid

For an arrangement that holds, the order of operations matters.

Control-click the desktop and choose Sort By > None. If Use Stacks has a checkmark, click it to turn it off. Only now does dragging mean anything permanent.

Next, choose Sort By > Snap to Grid. This is the setting most people actually want and almost nobody finds, because it lives in the same menu as the sorting options that fight with manual placement. Snap to Grid does not decide which icon goes where. It only makes each icon land on the nearest grid cell instead of sitting a few pixels off, so columns stay as columns without pixel nudging. Manual control is kept, sloppiness is not.

Then open Show View Options from the same Control-click menu. On the desktop it offers Icon size, Grid spacing, Text size, Label position, Show item info and Show icon preview.

Grid spacing is the underrated control. Widening it gives file names room so long names stop truncating. Tightening it is how thirty icons fit in the space that held twenty, which is worth more than shrinking the icons themselves, since small icons with tight labels become unreadable. Label position set to Right turns each icon into a compact row rather than a tall block, which suits a single column along an edge.

Show item info is a quiet win for anyone who keeps volumes or folders on the desktop, because it prints the item count under a folder and free space under a disk, turning decoration into a readout.

Why icons move after a display change

The most common complaint is not that macOS reorders icons. It is that unplugging or connecting a display scrambles them, and reconnecting does not put them back.

The reason follows from where positions are stored. There is one .DS_Store for the desktop folder, holding one set of coordinates. When the usable screen area shrinks, coordinates that fall outside the new area cannot be honoured, so those icons are reflowed to cells that exist. The coordinates that were overwritten are the only copy. Returning to the larger display gives back the space, but there is no second layout saved for that space to restore.

This is why the advice to arrange icons on the smallest display in the rotation actually works. A layout that fits a 13 inch built in screen also fits a 27 inch external one. The reverse is not true.

The same logic explains a subtler case: a resolution change from Displays settings, or a scaled resolution picked for a video call, is a change in usable area even though no cable moved. Screen sharing and recording setups that force a resolution do the same thing.

Rotating a display into portrait orientation is the extreme version. A tall narrow desktop has room for perhaps a third as many columns, so a wide layout collapses into a queue and the original spacing is gone for good. Anyone who switches a second screen between landscape and portrait through the day is overwriting the same single record twice a day.

A sanity check takes ten seconds and saves a lot of guessing. Note roughly where three icons sit, unplug the external display, look at where those three went, then plug it back in. If they return, the layout was never the problem and something else moved them. If they stay where the smaller screen put them, the reflow above is the whole explanation, and the fix is to arrange for the small screen rather than to keep repairing the large one.

Layouts that follow the display setup are something separate software adds rather than something macOS provides for desktop icons. Tools that manage the strip at the top of the screen have gone further here. A menu bar organizer can store one layout per display arrangement and swap between them automatically, which is the behaviour the desktop lacks.

What breaks a layout that used to hold

When positions stop sticking even with free placement set, the cause is usually one of four things, and they are quick to separate.

The index file cannot be written

If ~/Desktop/.DS_Store is not writable, positions last only until the Finder forgets them, which means until logout. Permission damage on the home folder, or restoring a home folder from a backup as a different user, produces exactly this. Deleting the file is also the standard reset: remove it, relaunch the Finder, and the desktop starts from a clean grid rather than from a half broken record.

Desktop and Documents are in iCloud Drive

With that option on, the desktop folder is a synced folder. Files arriving from another Mac are new files on this one, and they take free cells wherever those happen to be. Two Macs with different screen sizes sharing one desktop folder will keep nudging each other's layouts.

A sort mode was switched on and off again

Turning Sort By Name on for ten seconds to find something, then back to None, is enough. The manual coordinates were replaced while sorting was active.

Items appear that nobody put there

Disks and servers are drawn on the desktop only because the Finder is told to draw them, and each one occupies a cell. Finder > Settings > General holds the checkboxes for hard disks, external disks, removable media and connected servers. Turning off the ones that are not needed frees the corner they keep claiming, and the setting is per Mac, not per volume.

For a genuinely empty look without deleting anything, System Settings > Desktop & Dock has a Show Items group with an On Desktop checkbox. Unchecking it hides every item on the desktop while leaving the files exactly where they are, which is the honest version of tidying up.

The strip above the desktop obeys different rules

Anyone who cares enough to align desktop icons usually has a second, worse version of the same problem twenty pixels higher. The menu bar fills left to right with status icons, the newest arrival lands wherever it likes, and on a MacBook the notch eats the middle so the overflow disappears without warning.

None of the tools above reach it. Clean Up, Snap to Grid, Stacks and view options act on files in a folder. The menu bar holds status items owned by the system and by background apps, and macOS stores their order inside each app's own settings, which is why an order change only takes effect the next time that app starts.

That is the gap a menu bar manager fills: a divider with a hidden zone behind it, a way to bring hidden items back for a moment, and per display layouts so docking does not reshuffle the strip. The trade offs between the available options, including the free ones, are laid out side by side on the comparison page.

What to change first

Set Sort By to None, turn on Snap to Grid, then widen Grid spacing in Show View Options and arrange the desktop while on the smallest screen in the rotation. If the mess that actually costs time is the row of status icons rather than the files, a fourteen day trial of Koffret will show within a minute whether the top strip is the real problem.

Frequently asked questions

Why is Clean Up greyed out or missing from the menu?

Clean Up only appears when nothing else is placing icons automatically. Either a sort option is active or Stacks is on. Control-click the desktop, choose Sort By > None, and make sure Use Stacks has no checkmark.

What is the difference between Clean Up and Snap to Grid?

Clean Up is a one time action that pushes every loose icon onto the nearest grid cell right now. Snap to Grid is a standing setting that makes each icon land on a cell as it is dragged, without deciding the order. Snap to Grid is what keeps a hand made layout tidy over time.

How do I get my icons back to the left side of the screen?

macOS fills the desktop from the top right, so the left side has to be arranged by hand: turn on Snap to Grid, then drag the icons across. They will stay there as long as no sort option and no Stacks setting is switched on afterwards.

Will deleting .DS_Store delete my files?

No. The hidden .DS_Store file records only view information for that folder, such as icon coordinates, icon size and the sort setting. Deleting it resets the desktop to a default grid and the Finder creates a new one; the files themselves are untouched.

Can a Mac remember a different icon layout for each monitor?

Not for desktop icons. One set of coordinates is stored for the desktop folder, so the layout that survives is the one that fits the smallest screen in use. Per display layouts exist for the menu bar in third party tools, but not for files on the desktop.

Back to all posts