Rebuild Icon Cache in Windows 10  

Page 1 of 14 12311 ... LastLast
    Rebuild Icon Cache in Windows 10

    Rebuild Icon Cache in Windows 10

    How to Rebuild the Icon Cache in Windows 10
    Published by Category: Customization
    08 Nov 2019
    Designer Media Ltd


    How to Rebuild the Icon Cache in Windows 10


    The icons that display for files in Windows are saved in an icon cache so they can be displayed quickly instead of having to manually scan and slowly load them each time.

    The icon cache can sometimes become corrupted causing the icons of files to display incorrectly or distorted. When this happens, the icon cache needs to be deleted to reset and automatically recreate it.

    Rebuilding the icon cache will not help with the following icon issues:
    • The icon of a shortcut not displaying properly due to the target source of the shortcut was moved or deleted. You may need to recreate a new shortcut directly from the source (ex: program's exe) file to replace it instead.
    • All icons for a specific file extension display the wrong icon. This may be due to setting the wrong association for what app to open the file type instead. If so, restoring the default association of the file extension will fix this issue.
    • Thumbnails of folders, pictures, videos, and documents.

    This tutorial will show you how to rebuild the icon cache to clear and reset it for your account in Windows 10.


    Contents

    • Option One: To Rebuild the Icon Cache using a BAT file
    • Option Two: To Rebuild the Icon Cache in the Command Prompt






    OPTION ONE

    To Rebuild the Icon Cache using a BAT file


    1 Click/tap on the download button below to download the file below.

    Rebuild_Icon_Cache.bat

    Download

    Code:
    @echo off
    set iconcache=%localappdata%\IconCache.db
    set iconcache_x=%localappdata%\Microsoft\Windows\Explorer\iconcache*
    
    echo.
    echo The explorer process must be temporarily killed before deleting the IconCache.db file. 
    echo.
    echo Please SAVE ALL OPEN WORK before continuing.
    echo.
    pause
    echo.
    If exist "%iconcache%" goto delete
    echo.
    echo The %localappdata%\IconCache.db file has already been deleted.
    echo. 
    If exist "%iconcache_x%" goto delete
    echo.
    echo The %localappdata%\Microsoft\Windows\Explorer\IconCache_*.db files have already been deleted.
    echo.
    exit /B
    
    
    :delete
    echo.
    echo Attempting to delete IconCache.db files...
    echo.
    ie4uinit.exe -show
    taskkill /IM explorer.exe /F 
    If exist del /A /F /Q "%iconcache%"
    If exist del /A /F /Q "%iconcache_x%"
    start explorer.exe
    echo.
    echo IconCache database files have been successfully deleted.
    goto restart
    
    
    :restart
    echo.
    echo.
    echo You will need to restart the PC to finish rebuilding your icon cache.
    echo.
    CHOICE /C:YN /M "Do you want to restart the PC now?"
    IF ERRORLEVEL 2 goto no
    IF ERRORLEVEL 1 goto yes
    
    :yes
    shutdown /r /f /t 00
    
    :no
    exit /B

    2 Save the .bat file to your desktop.

    3 Close and save anything that you are working on before proceeding. The next steps will involve killing explorer and restarting the PC.

    4 Run the .bat file.

    5 When prompted, click/tap on Run to approve. If you like, you can unblock the .bat file to no longer get the Run (Open File - Security Warning) prompt. (see screenshot below)

    Rebuild Icon Cache in Windows 10-run_open_file_security_warning.png

    6 Follow the instructions in the command prompt to rebuild the icon cache. If you do not restart the PC now, you will need to later to finish rebuilding the icon cache. (see screenshots below)

    Rebuild Icon Cache in Windows 10-rebuild_icon_cache_command-1.png
    Rebuild Icon Cache in Windows 10-rebuild_icon_cache_command-2.png

    7 If the icons are still not displaying properly after rebuilding the icon cache, then download and merge the .reg file for the .ico (ICO) option here to restore the default associations of .ico (icon) files in Windows 10.







    OPTION TWO

    To Rebuild the Icon Cache in the Command Prompt


    1 Close and save anything that you are working on before proceeding. The next steps will involve killing explorer and restarting the PC.

    2 Open a command prompt.

    3 Copy and paste each command below one at a time into the command prompt, and press Enter after each command.

    ie4uinit.exe -show

    taskkill /IM explorer.exe /F

    DEL /A /Q "%localappdata%\IconCache.db"

    DEL /A /F /Q "%localappdata%\Microsoft\Windows\Explorer\iconcache*"

    shutdown /r /f /t 00

    This last command will instantly restart the computer.

    4 If the icons are still not displaying properly after rebuilding the icon cache, then download and merge the .reg file for the .ico (ICO) option here to restore the default associations of .ico (icon) files in Windows 10.


    That's it,
    Shawn



  1. Cliff S's Avatar
    Posts : 24,344
    Win10 Pro, Win10 Pro N, Win10 Home, Win10 Pro Insider Fast Ring, Windows 8.1 Pro, Ubuntu
       #1

    You're tutorial makes it much easier Shawn. I've been doing/recommending the long way(copy & pasted from my tips & tricks folder):


    To Rebuild icon cache follow the below mentioned steps

    1. Open a File Explorer window.
    2. At the top left click the view tab and select(check)"Hidden Items.
    3. Go to C:\Users\(User Name)\AppData\Local
    4. Right click on IconCache.db and click on Delete.
    Rebuild Icon Cache in Windows 10-screenshot-37-.png
    5. Click on Yes to confirm the deletion.
    NOTE: This deletes the fileto the Recycle Bin. It is safe to empty the Recycle Bin when finished.

    6. Close the window.

    7. Empty the Recycle Bin.

    8. Restart the computer.

    9. When you go back, you will notice the Size of the IconCache.dbfile is smaller, and the Date Modified is now the current date. (See screenshotbelow)
    NOTE: If for some reasonIconCache.db is not there or the size has not changed much, then just restartthe computer again. You may need to restart a couple of times in some cases.

    10. The icon cache has been rebuilt.
      My Computers


  2. Posts : 9
    windows 10
       #2

    Hi,

    Installed win10 desktop icon are build very slow when comparing with win 8.1.
    Did a manual delete of the icon cache file as described on the site. Did a cleaning with the latest tool recommended on this site.
    Even replaced my 'older (2Y)' hdd with a SSD (Samsung 850) the icons are build slow. What's happen??? The icons are first displayed as a white background.
    After that the icons are build with the real program icons one by one (very slow)
    Any help is appreciated (latest drivers from my graphic card are installed also the latest MS updates are installed)
    Kind regards

    Al
      My Computer

  3. Brink's Avatar
    Posts : 48,984
    64-bit Windows 10 Pro for Workstations build 19640
    Thread Starter
       #3

    Hello Al, and welcome to Ten Forums. :)

    It sounds like something may be using up your system resources causing the slow down.

    It depends on your system specs, but you might see if troubleshooting with a clean boot may help to reveal a cause.

    Troubleshoot Problem with Clean Boot in Windows 8
      My Computers


  4. Posts : 6
    Win 10 pro 64 bit
       #4

    I think my problem started when I saw a reference (forget where) to the effect that "shutdown", followed by a new power-on, does not do a clean restart of machine/Windows. To get a clean start you can use the StartButton>Power>Restart function. So, I tried it :-( It does get a bit busier and takes longer. But when Restart finished, I was missing some (2-3 of ~30) of the icons on my desktop. Sort of missing anyway. The Desktop folder in File Explorer contains all that should be on my desktop. The icons were shortcuts to batch files, and to folders. When I tried to recreate the shortcuts, the label gets "(2)" added to it. My desktop shows a Thumbs.db icon, and two desktop.ini icons. all grayed out. (these have been there on W7 before I went to W10.

    The tutorials looked promising, I confirmed that the iconcache.db was deleted. But icons still missing.
      My Computer

  5. Brink's Avatar
    Posts : 48,984
    64-bit Windows 10 Pro for Workstations build 19640
    Thread Starter
       #5

    Hello Periboob, :)

    It sounds like they may just be hidden since you got a "(2)" in the name when trying to add them back. As a test, right click on your desktop, click on View, and make sure that "Show desktop icons" is checked.

    https://www.tenforums.com/tutorials/6...dows-10-a.html
      My Computers


  6. Posts : 6
    Win 10 pro 64 bit
       #6

    Thanks Brink, but "Show desktop icons" already checked. Any other ideas welcome. Just on a whim, I opened a command window at the Desktop folder, and "type"d both the .lnk files for one that had disappeared. File contents appear identical to the human eye at least. This suggests to me that the problem is not in the contents of these files, but rather system instruction of some sort.
      My Computer


  7. Cliff S's Avatar
    Posts : 24,344
    Win10 Pro, Win10 Pro N, Win10 Home, Win10 Pro Insider Fast Ring, Windows 8.1 Pro, Ubuntu
       #7

    Did you moved those bat files and folders, maybe. Windows stores the path in the registry for shortcuts, but not the actual address. For example if, not thinking I move an icon or wallpaper to another folder, or put it in one even, the path changes and I get a blank(white sheet of paper as a place holder, but no shortcut/wallpaper.
      My Computers


  8. Posts : 9
    Windows 10
       #8

    Rebuild Bat link down.
      My Computer

  9. Brink's Avatar
    Posts : 48,984
    64-bit Windows 10 Pro for Workstations build 19640
    Thread Starter
       #9

    Hello vbcrayon, and welcome to Ten Forums. :)

    The .bat download seems to be working fine for me.

    https://www.tenforums.com/attachments...icon_cache.bat

    What browser are you using? Any download managers?
      My Computers


 

Tutorial Categories

Rebuild Icon Cache in Windows 10 Tutorial Index Network & Sharing Instalation and Upgrade Browsers and Email General Tips Gaming Customization Apps and Features Virtualization BSOD System Security User Accounts Hardware and Drivers Updates and Activation Backup and Restore Performance and Maintenance Mixed Reality Phone


Related Threads
Our Sites
Site Links
About Us
Windows 10 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 10" and related materials are trademarks of Microsoft Corp.

Designer Media Ltd
All times are GMT -5. The time now is 04:57.
Find Us




Windows 10 Forums