40

Is it possible to hide desktop.ini on the desktop, but show it when viewed in Windows Explorer?

Essentially, I need to be able to see hidden and system files when using Windows Explorer, but I don't like the two desktop.ini files on my desktop (using Windows 7, 8, and 8.1). Is there a way to hide those two files on the desktop only?

3
  • 1
    Do you need to keep the desktop.ini files on the desktop? They are really only used to provide filenames and icons for system shortcuts (eg if you copy a link to Solitaire or Notepad to the desktop). However, the shortcuts work and look just fine without them.
    – Synetech
    Mar 14, 2011 at 17:49
  • No, I don't need to keep the desktop.ini files on the desktop, but they will re-generate frequently. As such, I am looking for a more general solution. Mar 14, 2011 at 18:47
  • 1
    Frequently? Are you copying shortcuts that came with Windows to the desktop frequently? If not, then you may want to look into why they keep coming back (especially if two copies keep coming back). Open them and see what’s inside; that should give you a clue as to what caused it to be created.
    – Synetech
    Mar 14, 2011 at 18:54

6 Answers 6

14

I found a solution on this site.

Use RegEdit to edit a DWORD registry key (or create a new key if it doesn't exist).

Go to

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\Explorer\

and create or edit key: UseDesktopIniCache and set it to 0 (zero).

Delete any desktop.ini files on the desktop and they will never reappear.

1
  • 1
    This should be marked as the correct answer. Works perfectly. Thank you. :-)
    – Apache
    Jan 3, 2017 at 19:33
13

It turns out that deleting Desktop.ini was the best solution. It does not regenerate frequently enough to be annoying.

1
  • 1
    Sadly, deletion is only possible with admin rights. May 2, 2018 at 15:14
10

This is a little cheesy, but works for me:

1) Right-click on the desktop and un-select 'align icons to grid' (and also 'auto arrange icons' if you have that on).

2) Drag the desktop.ini files off the edge of your screen. While they are selected, you will still see a sliver of highlight, but once you click off them you will not see them at all.

The only problem is if you ever turn auto-arrange or auto-align back on, they will pop back into view.

1
  • nice workaround
    – beppe9000
    Nov 11, 2017 at 16:08
0

To recap:

  1. Open Windows Explorer.

  2. Click Organize, Folder and Search Options.

  3. Click the View tab.

  4. Click to UNHIDE protected system files.

  5. Click Apply to all folders.

  6. Navigate to your profile's desktop.

  7. Repeat steps 2 & 3.

  8. Click to HIDE protected system files.

  9. DO NOT click Apply to all...

This will let you see ALL the protected files and folders EXCEPT the desktop.ini files on your actual desktop.

2
  • 6
    This doesn't appear to work in Windows 7. The "Hidden files and folders" options apply to all folders when the "Apply" button is clicked.
    – sdoca
    Apr 6, 2011 at 16:04
  • This is my experience, too. It seems to be explorer-wide for some reason!
    – sandos
    Oct 21, 2016 at 13:16
0

You could try this (worked with older Windows): Go to your user folder, and then folder "desktop". You will now see your desktop as a regular folder. Then, go to top menu, folder options, "View" tab (the one in the middle of that pop-up), and configure it as wished. In this case, forcing not showing system neither hidden files in this specific folder. (Don't hit "apply to all folders" button.)

Provided you had previously set to show system and hidden files for all folders (actually clicking in the mentioned "apply to all folders" button) in, for example, the main disk folder (that is, C:) so that all folders would show those files... Doing this after my first explained step (sorry for the mess) should keep that configuration only for the desktop folder.

5
  • 3
    Are you sure that works? I wrote a program to parse and display the Shell\Bags information and there was never a field for showing hidden files, that is a global setting: HKLM\…\Folder\Hidden\SHOWALL, not only not per-folder, but not even per-user.
    – Synetech
    Mar 14, 2011 at 17:47
  • 1
    True, I was curious and was just now discovering this now... It was an old trick working pretty well dunno if with Win XP or even older ones,(you had a setting that "remembered each folder" settings) but not in Windows 7. Looks like the only chance (apart from touching the registry) is to just set it to show all, and delete manually the desktop.ini file...
    – S.gfx
    Mar 14, 2011 at 17:57
  • 1
    Actually, I meant XP. Shell\Bags in XP did not have a show-hidden field. I’m pretty sure that it has always been a global option.
    – Synetech
    Mar 14, 2011 at 18:18
  • The funny thing is I remmember being able to do this in XP... might have skipped some step of the trick...
    – S.gfx
    Mar 14, 2011 at 18:25
  • @S.gfx XP did not put a desktop.ini on the desktop.
    – kinokijuf
    Dec 26, 2013 at 23:03
0

If you want to only hide this two desktop.ini files, based on what Barc777 and studiohack posted, just hide protected system files for the Desktop. Don't do all other steps or you will change your configuration globally:

  1. Open Windows Explorer
  2. Click/navigate to Desktop
  3. Click Organize -> Folder and Search Options
  4. Click hide protected system files, under View tab.
  5. Click Accept at the bottom of the window (do NOT apply to all folders).

This way, only the Desktop view is modified.

3
  • 1
    Your steps change it globally for me.
    – xr280xr
    Apr 1, 2013 at 14:46
  • Same here, it hid all other hidden files and folders in the system.
    – Calimo
    Apr 11, 2013 at 10:30
  • 3
    -1 The "Folder and Search Options" entry is on a global menu. Meanwhile, the "Apply to all folders" button doesn't refer to the settings in the section below it. That's why it is separated into its own section. It can be confusing because they're on the same tab. Jun 3, 2013 at 19:38

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .