How to Prevent Desktop INI From Being Created (Easy Guidelines)

  • Post author:
  • Post category:How To
  • Post last modified:January 28, 2023
  • Reading time:6 mins read

Desktop.ini is a file that stores the arrangement of a windows folder. You can prevent the creation of the destop.ini files. They are usually hidden. When you change the configuration and the layout of a folder, it is saved in the desktop.ini files. If you do not make any changes in a folder, they won’t be created.

How to Prevent Desktop INI From Being Created

Is Desktop.ini File A Virus

No, the desktop.ini file is not a virus. They are system files that are automatically created while changing in the file explorer. But the Trojan virus can hide its identity by the name of desktop.ini. They can add many of these .ini files. 

You can not identify them because of their name. They will affect your laptop and folders. You can delete the virus and the affected files. You will lose the affected file. So, deleting those files will be the right option. 

How Can I Prevent Desktop.ini From Creating

Preventing the creation of desktop.ini is way better than hiding it. Follow the steps:

1. First, press start and open the registry editor using the search bar. Or press start + run, then type Regedit and click on ok.

2. Then navigate to the dword key below:

HKEY_LOCAL_MACHINE —> SOFTWARE —> Microsoft —> Windows —> CurrentVersion —> Policies —> Explorer

3. Now create a dword value name as “UseDesktopIniCache” and data as “0”

You Also Can Follow an Alternative Way. That Is

1. Paste the code below to an empty file and then save the file as a registry file (.reg).

  1. ##
  2. # Early Windows Version
  4. [HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\Explorer]
  5. “UseDesktopIniCache”=dword:00000000
  6. # Late Windows Version
  7. Windows Registry Editor Version 5.00
  8. [HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\Explorer]
  9. “UseDesktopIniCache”=dword:00000000
  10. ##

2. Now double-click on the registry file and then add the key from above. 

Can I Delete Desktop.ini Files Altogether

Yes, you can delete the desktop.ini file as a regular file. It will not cause any harm to the computer but it will restore your customized configuration to the default. The desktop.ini file can be hidden on your file explorer. So, you need to enable the hidden items from the view tap of the file explorer.

Open ‘File explorer’ and click on ‘view’ from the ribbon menu. Now open ‘options’. Under folder, options click on the ‘view’ tab. Then check the ‘Show hidden files, folders, and drives’ and uncheck ‘hide protection operation’

Now you will be able to see and delete the desktop.ini files. Right-click on the file and click to delete. You can also delete the files using the run command. Press ‘Windows + R’. Then type ‘cmd’ and press ‘ok’.

How Can I Hide Desktop.ini Files?

Follow the steps:

  1. Open file explorer.
  2. Navigate to the ‘view’ tab.
  3. Select ‘options’.
  4. Select the ‘view’ tab under folder options. 
  5. Now check the ‘Hide show hidden files, folders, or drives’ and also check ‘hide protection operation’.
  6. Then click on ‘apply’ and ‘ok’.


In this article, we have discussed desktop.ini files. Desktop.ini files are not a virus. They are system-created files. The files can be deleted as regular files. Desktop.ini files are usually hidden. Desktop.ini file can be prevented from creation. The file may only appear when certain changes are made in a folder.

Leave a Reply