Nevermore Be Bothered by Desktop.ini

I get annoyed by the superfluous.  It’s just one of those traits I possess.  Maybe you have similar quirks. I wouldn’t know.  However, if you (like me) don’t see the point in cluttering up a perfectly good system with an ass-load of Desktop.ini files here is the basic solution.

You will see a lot of articles out there saying, essentially, “hide your hidden files”.  Not quite the same.  Especially if you don’t want to hide hidden files.

  1. Open the registry editor ( Start —> Run —> regedit )
  2. Locate or add the following DWORD key: HKEY_LOCAL_MACHINE —> SOFTWARE —> Microsoft —> Windows —> CurrentVersion —> Policies —> Explorer —> “UseDesktopIniCache”
  3. Modify that key so that it’s Value is 0 (zero)

Admins, alternatively you can paste the following code into an empty text file and save it as a registry file (like nomoredesktopini.reg).  Double-clicking that reg file will then add the key as described above.


# Early Windows Version



# Late Windows Version

Windows Registry Editor Version 5.00



(Use the pointy-bracket button to get a clean copy/paste version of the code.)

For early versions of Windows try using the key which begins “REGEDIT4“; for later versions (certainly by Win8) you’ll want to use the “Windows Registry Editor Version 5.00” formulation.  If both of those fail you will have to make the registry edit manually (which will likely involve creating the registry key) as outlined above.

Windows will stop making them by default.  If you make a customization, I think Windows will create one for that; and you can always create your own Desktop.ini files if you are so inclined; this hack merely prevents the operating system from automatically creating them.

This fix should work from WinXP 32 bit through Win8.1 64 bit and all points in between.

Note: In the comments you will see some write of the key located at HKEY_LOCAL_MACHINE —> SOFTWARE —> Wow6432Node. This should be automatically created if the location above is created. Adjust according to your experience.

Have fun with that.


61 thoughts on “Nevermore Be Bothered by Desktop.ini

    1. It can be used in some instances. It would hold things like folder customizations.

      What Are Those Desktop.ini Files I Keep Seeing @ HowToGeek

      (This article also includes information which might help someone in making their own Desktop.ini files.)

      I never use them, but if you find that something isn’t pretty like you wanted it you may have to reverse the process to return their creation. I don’t believe this will delete currently existing files but rather will prevent them from being created in the future.

      You can either make a note of the registry key information before you change it or you can save the key someplace before you change it (and then use that saved key to restore it later if you don’t like it).

      (To save a key right-click on the containing folder and choose Export.)

    2. Windows Registry Editor Version 5.00


      ;use this for windows 8 reg file

    3. I appreciate your work on this, and I’m glad it works for you and others. It doesn’t work here–Win7 Enterprise, Server 2003 Standard, XP/Pro.
      Added subkey HKLM/Software/Microsoft/Windows/CurrentVersion/Policies/Explorer/UseDesktopIniCache with a 0 value. Has no effect on any of these systems.


    1. I haven’t tried this in Win8. Have you tested it and confirmed it does not work?

      Oh, and don’t kill dogs. They don’t deserve your ire. Kill mosquitoes. Think about it: if they were to suddenly go extinct, would there be a single notable negative consequence? It’s the only creature I can imagine yearning for its extinction. Fucking mosquitoes.


      I was not able to import the key using the usual method. I’ll have to look into that. I was able to right-click in the correct location in the Registry Editor and create a new key (dword), name it as outlined above, and give it a value of zero.

      I’m not clear how to test this since I’m not clear at what juncture Windows might attempt to create a Desktop.ini file. If this method fails, perhaps the solution is using a qword instead?

  1. Yes, I have your registry setting but c:\Users\Denis\Desktop\desktop.ini gets recreated every time I log in (Windows 8 64-bit).

    BTW, the path in your reg fie contents above should of course be [HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\Explorer], you have lost some backslashes.

    1. Yeah, you should be able to right-click in the right-hand pane and choose New –> DWORD and set it to the name mentioned with a value of 0.

      It may be necessary to use a QWORD for 64 bit systems; I’m not clear on that point yet.

      Hopefully someone can let us know more details.

  2. Im running Windows 8.1 your method isn’t working… but when i open the file this is what is written in there :


    If it helps… I just don’t want to mess up my windows by doing something wrong. :) i don’t have much experience with configuring windows files and such.

    1. Yeah, that’s what I would call “default”. This file is meant to hold certain customizations for its containing folder (like if you want a special icon for that particular folder). The OS should really only create them when there has actually been any customization.

      I’m not running Win8 myself (and we here at work are violently avoiding it). The official MS response has been “hide hidden files” (as can laughably be seen in this post which utterly fails to answer the original question).

      (I’m going to guess those three likes were from other MS employees patting their buddy on the back.)

      Did you try both a dword and a qword? Let me know if you discover anything which might be useful.

  3. Hi,

    I reloaded an image and did a quick test… Since I already had desktop.ini files on my desktop, I couldn’t test as to whether this regedit would prevent them…

    The deleted ones didn’t return, but they didn’t return without the regedit either…

    As I mentioned, everything on my desktop was unchanged after deleting them…

    However… I created a new empty folder on my desktop, which had the standard folder icon, and ended up containing no desktop.ini file…

    I changed the standard folder icon to a STOP icon. This created a desktop.ini file in the folder.

    I then deleted the desktop.ini file in the empty folder, and the STOP icon disappeared and was replaced with the standard folder icon..

    BTW… the batch file I created from your info did in fact create the registry key in Win 8.1.

    I modified it slightly from your article… basically I left out some blank spaces to get this…


          1. It looks like this is what works:

            While at it, you can disable thumbs.db too:

          2. Zsolt – I’m sorry you had troubles. My 8.1 system doesn’t have the path in regedit you have specified (HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\ yes but no Explorer). Are you certain of that path? I have at least three persons who have confirmed the edit I posted is working with 8.1 systems.

  4. Hi guy’s, Love the discussion. I have the same problem, but I have always just deleted them. Silly question maybe, but I was thinking if there are multiple desktop.ini files created in the same folder, wouldnt they need a different name ? Or is that why I have found one in my Documents Folder … I havnt had multiple desktop.ini files on the desktop because as I said I usually delete them soon after they appear….. Never noticed any issue’s with programs etc after deleting. Running 8.1 pro on a desktop .

    1. Doug — You are correct: you cannot have more than one file with the same name in the same location (and for Windows that means regardless of case). Either Windows will modify an existing file or it will create one if none yet exists.

  5. Hi Doug, newer versions of ms windows use a trick called folder redirection to mess up your head, err, i mean to operate correctly. A good example is the desktop that you see. It is actually made up of the contents of 2 Desktop folders, a global one and a personal one, as well as some non-physical stuff stored in the registry. This means that you can have at least THREE “folder objects” with the same name in your viewable desktop. The viewable desktop itself is NOT a folder or directory but a class of virtual container folder object known as a “namespace”.

    thanks for the post Jamesisin, just before coming here I did a search for Thumbs.db and Desktop.ini in my registry and of course found nothing, lol I’m getting to old to drop a dot.

    1. LLayr – To be clear, folder re-direction and namespaces are not the same, but thanks for the additional information on the Desktop folder (which is not technically a folder). This explains nicely why sometimes I do see a pair of Desktop.ini files on a Desktop.

  6. I only know that these files are impossible to hide from view if I use any of these proposed solutions, and believe me I have been trying to hide these desktop.ini files for years. I am sick for reading ridiculous and farfetched solutions.

    So then it occurred to me to research into a file and folder hiding software.

    Since I already had “Hide Folders” in my larder of software, I fired it up and read the manual on hiding groups of files by their extension (e.g. “.ini”)

    What I came up with is a command to enter into Hide Folders that literally hides ALL my desktop.ini files on any drive I choose: e.g. C drive = C:\*Desktop.ini and if that is not posting then the code is capital C > colon > BACK slash > Star, or Asterisk > Desktop.ini

    Now what this did is it hid every single Desktop.ini file in my C drive. Even when I deselected the “Hide protected folders blah blah” boxes, these files remained hidden.

    I further tested them by changing their color and adding comments to them WinLabels and HOB Comment. Everything worked well, and when I “unhid” them using Hide Folders and opened the Desktop.ini files, the coding had changed as well.

    So, I knew that even though these files were being hidden from all view by Hide Folders, Hide Folders was not interfering with their function.

    So this is my 100% guaranteed solution that has nothing to do with tweaking Windows.

    The only thing you must remember is that when you delete any hidden Desktop.ini file to the Recycle Bin and then try to subsequently delete the recycle bin, YOU MUST FIRST UNHIDE DESKTOP.INI > Delete the recycle bin, and the again hide the .ini files. That was the only thing that I had to figure out after some error pop ups.

    So, I am nevermore bothered by my desktop.ini files, yet they are allowed to exist to do what they are supposed to do, and I do not have to operate and remove anything through the registry.

    Thank you for letting me share a guaranteed solution that has bothered me for years, and NOTHING other than this has worked to prevent these from being created over and over, or any changes being reset on restart and the darn things come back. Only this has worked for me so far, and I have put it through every test that any of you have more than likely read about over the weeks, months and years.


    1. Sounds like a cool hack, John. Since I see no use in the files (and the changes they represent) I am content in inhibiting their creation. I suppose if I really wanted to could write an algorithm to remove any existing Desktop.ini files, but I probably won’t.

      I like your work-around because it works on all drives (local, attached, mounted), which of course is an advantage when you attach to someone else’s drives.

      A cursory search did not yield something definitive, so if you have a moment could you link to the application you used?

    1. Looks like that’s probably the application, Duncan. Thanks. I probably won’t use it but others may enjoy having it.

      (I use Ubuntu myself and really am in full control of my OS.)

  7. hi!
    i have windows 8.1 x64, and the first one with REGEDIT4 didn’t work.
    i tried the second one – the one with Windows Registry Editor Version 5.00 and it didn’t work.
    i was reading comments, so i tried the third one, i mean :
    it didn’t work.
    what should i do?

  8. i made a text file and run the code, the key now exist in my registry at:
    1 – HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\Explorer\“UseDesktopIniCache” – it’s value is 0.
    2 – HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\Explorer\“UseDesktopIniCache” – it’s value is 0.
    but still when i delete desktop.ini, after a while i see another one. please help me!

    1. iambb — I just tested it on another 8.0 64 bit system (don’t have an 8.1 handy) and it works as expected. I navigated to that container (HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\Explorer), right-clicked and created a dword called “UseDesktopiniCache”, and made sure its value was 0. Unless you are creating customizations for the folder in question (which may yet create an ini to house that customization) this should prevent them from automatically being created. Did you miss “Current Version” in your path?

      1. This isn’t working for me either on Windows 7 Entreprise 64bit SP1.

        Created the dword:
        HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\Explorer\ UseDesktopIniCache with a value of 0.

        Then it automatically replicates to:

        Restarted computer, logged as a new user on the computer so the profile is clean, and desktop.ini files are created inside de profile.

  9. Same problem as Private here. NOT part of default profile, replicates to the HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Microsoft\Windows\CurrentVersion\Policies\Explorer location on creation. Same key, same value. Still the same problem.

    Solution doesn’t work on Win 7 x64 Enterprise.

    1. Karlos – If you are experiencing the same thing as Private, then see my response to Private. If you sign in as a user that has never signed in previously, that user gets a profile created from a default profile. You can, if you’d like, delete all the Desktop.ini files from the default profile (or from your entire system to go further) and this would prevent those files from being cloned when you sign in as a new user.

      This solution certainly works on Win7 64bit Enterprise since that is what I run at work all day long (and where I began testing this solution, in fact).

  10. My Win8.1 o.s. registry already had this reg key under [HKEY_LOCAL_MACHINE\SOFTWARE\WoW6432Node\Microsoft\Windows\CurrentVersion\Policies\Explorer]

    I created another one anyway using the path you outlined in this article. =)

    All is good . Thanks

  11. Hi,

    This is not working in Windows – 7 Prof – 64 bit.

    Created the dword and also qword:
    HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\Explorer\ UseDesktopIniCache with a value of 0.

    After making the above changes in the regedit, manually deleted the D:\$RECYCLE.BIN directory through command prompt. Rebooted the machine and logged in to the same account where i previously changed the registry entry. But Still the desktop.ini file is getting created under D:\$RECYCLE.BIN\

    1. My guess here is that when Windows recreates the directory it is just copying it from some CAB or similar and that original has a Desktop.ini file in it. Try just deleting the Desktop.ini file instead.

    1. Greg – You can try the reg-key-file method (save the information as a file and run that file), but that is likely also locked down by our admins. Otherwise you’ll have to convince them this is a good thing to do.

  12. I only get these every time a new folder is created in Google Drive. Since I use Google Drive regularly (38,000 files in it), that’s a lot of desktop.ini files. I haven’t found a solution. I have, however, found a way to make myself feel better. I use an awesome free program called Agent Ransack to find all desktop.ini files inside my Google Drive (windows search never finds them). Then select all, delete. Ahh. *sits back, sips coffee*

  13. DOS command line:

    reg add “HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\Explorer” /v UseDesktopIniCache /t REG_DWORD /d 0 /f

  14. Good on you JameIsIn!

    This worked for me. I’m using Win 8.1 64 bit. I didn’t use the reg file with this in it:
    Windows Registry Editor Version 5.00


    – but I manually added that UseDesktopIniCache value with a zero DWORD into that key. (I expect the reg file would have worked though.)
    Then I deleted all the desktop.ini files wherever I wanted.
    Then to ensure the registry setting was effective, I logged off then back on.
    Now no more desktop.ini files are re-created!

  15. Well I tried this UseDesktopIniCache setting on my Win 8.1 64bit laptop – it seemed to work for a little while until I added a file into the “Documents” folder – then the pesky annoying Desktop.ini file was recreated! My “Documents” folder is actually “E:\MD” and that is what I want to see! I don’t want Windows taking over and making it look like it is called “Documents” every time a Desktop.ini file is created there!!! Why oh why oh why doesn’t Microsoft have a real solution to completely stop the creation of Desktop.ini files ‘all over the place’? Why aren’t Microsoft very good listeners to what their customers want?

Leave a Reply

Your email address will not be published. Required fields are marked *