To show icons faster, Windows caches them into a file. However, the icon cache file size is just 500 KB by default. Due to this restriction, folders with many files may open slowly. Increasing the icon cache size may resolve the issue and fix slow loading icons in the File Explorer. You can further increase the icon cache size and set the Max Cached Icons value to 8192 = 8 MB.
Code
:: Change Icon Cache Size in Windows 7, Windows 8, and Windows 10.
@Echo Off & Cls
net sess>nul 2>&1||(powershell start cmd -ArgumentList """/c %~0""" -verb Runas & exit)
Cls & Mode CON LINES=11 COLS=60 & Color 0E & Title Created By FreeBooter
Echo.
Echo.
Echo.
Echo.
Echo Change Icon Cache Size to 8 MB (Y/N)?
Echo.
Echo.
Echo.
Set /p input= RESPONSE:
If /i Not %input%==Y (Goto :_Ex) Else (Goto :_Start)
:_Ex
If /i Not %input%==N (Goto :EOF) Else (Goto :_RegRestore)
:_Start
Reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer" /v "Max Cached Icons" /t REG_SZ /d "8192" /f >Nul
Cls & Mode CON LINES=11 COLS=50 & Color 0E & Title Created By FreeBooter
Echo.
Echo.
Echo.
Echo.
Echo Increasing Icon Cache Size
Echo.
Echo.
Echo.
Ping -n 6 localhost >Nul
CHOICE /C YN /M "Press Y to Reboot, N for exiting script."
If %errorlevel% == 1 ( Shutdown /r /t 0) Else (Exit)
:_RegRestore
Reg.exe delete "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer" /v "Max Cached Icons" /f >Nul
Cls & Mode CON LINES=11 COLS=50 & Color 0E & Title Created By FreeBooter
Echo.
Echo.
Echo.
Echo.
Echo Restoring Default Icon Cache Size
Echo.
Echo.
Echo.
Ping -n 6 localhost >Nul
CHOICE /C YN /M "Press Y to Reboot, N for exiting script."
If %errorlevel% == 1 ( Shutdown /r /t 0) Else (Exit)
