How to Auto-Arrange Desktop Icons?

How do I enable auto-arrange (not just “auto-align”) for desktop icons, like in Windows?

Here is Solutions:

We have many solutions to this problem, But we recommend you to use the first solution because it is tested & true solution that will 100% work for you.

Solution 1

There’s no such feature to enable in Ubuntu. See this wishlist bug report about the feature request (it’s from 2005…).

Solution 2

I wrote iconic to solve this problem by letting you define a grid size larger than the icons. Additionally it will:

  • Allow you to move icons to any of three monitors
  • Not suffer the “lost icon syndrome” that occurs when monitors of multiple resolutions are used
  • Sort icons alphabetically, alphabetically with “Link to” prefix ignored, sort by modified date ascending or date descending
  • Allow different grid size (columns x rows) depending on monitor, EG more on 4K monitor than 2K monitor
  • Instant Test button for quick experimentation on column x row changes or reserved space changes for monitor left, top, right or bottom areas
  • Test button will last for x seconds defined by you, clear all windows before test and restore them after test
  • Bash script for easy modifications

You can get the script on github.

Here’s the main screen:

iconic main menu.png

Visit the github page for iconic to see all the other screens, explanations and a copy of the script.

Solution 3

Just a little modification for Ubuntu 17.04, you need to right click, select Keep Aligned and then Organise Desktop By Name.

Solution 4

Wow, 10 year old question, and it’s still a relevant search result. In the latest LTS (at time of writing!) Ubuntu 20.04, the used the half-baked desktop-icons Gnome Shell extension, which is missing many basic features, like drag-and-drop interaction with Nautilus. Reading posts, forums, and issue tracker complaints, I gather than this is because decision-makers of some kind decreed that desktop icons are an antipattern and they would prefer not to support them at all.

But, there’s a fork of their desktop-icons extension called "Desktop Icons NG (DING)" that solves the drag-and-drop, but development seems to be slow, s.t. newer version of it are not compatible with newer versions of Gnome Shell (what?), so their v18 addition of the arrangement feature is not available in the v17 that gets installed on my Ubuntu. (Why anyone would develop against the upstream version of Gnome, that gets used by approximately 1% of of the 1% of the world computer population who use Linux; is beyond me.)

SO! tl;dr, I installed a fork of DING "desktop-icons-neo", and it has all the features you’d expect Ubuntu to have out of the box. Just went to it on the gnome extensions site, flipped the switch to "on", disabled the built-in "Desktop Icons" in the built-in "Extensions" settings app, and then had the desired features in my desktop context menu.

But yeah, Linux will become the dominant desktop operating system any day now, sure.

Solution 5

Right-click on Desktop and click on Clean up by name

Solution 6

Running Ubuntu 16.10 (Lubuntu Desktop)

  1. Right click desktop, click ‘Select All’ (or hit CTRL-A)
  2. Right click on any icon, select ‘Snap to Grid’


Solution 7

Solution for Lubuntu (PCManFM):

  1. Go to /home/USER/.config/pcmanfm/default/ or /home/USER/.config/pcmanfm/lubuntu/.

    Change USER to be your username.

  2. Run: sudo nano pcmanfm.conf

  3. Go to the section: "[desktop]"

  4. Change sort_by to sort_by=2 (if you want to sort by name).

  5. Log out, then log back in. Tadaaa! 🙂

I’m not an expert, probably there is some nicer way to do that with bash script or something..but this works and it is needed to be done only once. About sorting numbers I’m not sure which one is for what and didn’t find any useful info, so you’ll need to discover it by yourself by playing or finding some info.

I’m not sure would something similar work for Ubuntu and Nautilus.

Solution 8

For Ubuntu 20.04
Written on Friday June 19, 2020 by walterflash

  1. Open nemo by opening a terminal and typing nemo. Hit enter.
    How to Auto-Arrange Desktop Icons?
  2. Your home folder should pop up.
    How to Auto-Arrange Desktop Icons?
  3. Now right click. You should see the command: Arrange Items. You can arrange the icons by Name, Type, Size or some other way.

Solution 9

Replace Nautilus by Nemo as Desktop managerment.

  1. Install Nemo (test in Ubuntu 16.04, install Nemo 3.6; Nemo 2.xx is not support arrangement desktop; Ubuntu 18.04 use Nemo 4.x):

    sudo add-apt-repository ppa:webupd8team/nemo3
    sudo apt update
    sudo apt install nemo
  2. Disable Gnome desktop icon:

     gsettings set org.gnome.desktop.background show-desktop-icons false
  3. Enable Nemo desktop management:

     setsid nemo-desktop

    After this command, you can Ctrl+c, the nemo-desktop is running in background.

  4. Adjust horizontal-grid-adjust if need:

     gsettings set org.nemo.desktop horizontal-grid-adjust 0.8

    Use can config in dconf-editor:

    How to Auto-Arrange Desktop Icons?

  5. Finally, use need set nemo-desktop as startup application. Follow this link.

  6. Enjoy !!

    How to Auto-Arrange Desktop Icons?

Note: Use and implement solution 1 because this method fully tested our system.
Thank you 🙂

All methods was sourced from or, is licensed under cc by-sa 2.5, cc by-sa 3.0 and cc by-sa 4.0

Leave a Reply