How to Reset Taskbar Settings to Windows Defaults

Corruption of Taskbar settings can cause it not to retain your customizations, such as auto-hide, icon size, or toolbar preferences. Also, in some situations, the taskbar may not be docked to a particular position. This post has a script that quickly resets the taskbar configuration for your user account to defaults.

completely reset taskbar
Fig 1: Corruption of Taskbar settings, causing a gap at the bottom.

Reset Taskbar to Default

Here is a VBScript that will clear your Pinned taskbar shortcuts, remove the toolbars added to Taskbar, and clears the past notification icons. The script can be used on Windows Vista, 7, 8, 10, and 11.


'-----------------------------------------------------------------------------
'Resets the Taskbar configuration
'This script can be used in Windows Vista, 7, 8 and 10.
'© 2016 Ramesh Srinivasan
'Created on March 24, 2016; Reviewed on April 24, 2021.
'https://www.winhelponline.com/blog
'-----------------------------------------------------------------------------

Set WshShell = WScript.CreateObject("WScript.Shell")
strRegPath = "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\"
strkey0 = "HKCU\Software\Classes\Local Settings\Software\Microsoft\Windows\CurrentVersion\TrayNotify\"
strkey1 = strRegPath & "StuckRects2\"
strkey2 = strRegPath & "StuckRects3\"
strkey3 = strRegPath & "Taskband\"
strkey4 = strRegPath & "Streams\Desktop\TaskbarWinXP"

sMsgTitle = "Taskbar Settings Reset"
sMsgCompleted = "Taskbar settings have been reset."

ExitExplorerShell
WScript.Sleep(3000)
ClearTaskbarSettings
WScript.Sleep(2000)
StartExplorerShell

Sub ExitExplorerShell()
	strmsg = "Explorer Shell will be terminated now. Click Yes to continue."
	rtnStatus = MsgBox (strmsg, vbYesNo, sMsgTitle)
	If rtnStatus = vbYes Then
		For Each Process in GetObject("winmgmts:"). _
			ExecQuery ("select * from Win32_Process where name='explorer.exe'")
	   		Process.terminate(1)
		Next
	ElseIf rtnStatus = vbNo Then
		WScript.Quit
	End If
End Sub

Sub StartExplorerShell()
	WshShell.Run "explorer.exe"
	strWelcome = "For more tips and articles on Windows, visit us at:" & Chr(10) & Chr(10) & vbtab & "https://www.winhelponline.com/blog"
	MsgBox "Completed!" & Chr(10) & Chr(10) & strWelcome & Chr(10),64, sMsgCompleted
End Sub

Sub ClearTaskbarSettings()
	On Error resume Next	
	WshShell.Regdelete strkey0 & "IconStreams"
	WshShell.Regdelete strkey0 & "PastIconsStream"
	WshShell.Regdelete strkey1
	WshShell.Regdelete strkey2
	WshShell.Regdelete strkey3
	WshShell.Regdelete strkey4
	On Error goto 0
End Sub

  1. Download taskbar_reset.vbs or create the script file by manually copying the above code to Notepad.
  2. Double-click the script file to run it.
  3. Click Yes to continue.
    reset taskbar script

The script takes 5 seconds to execute (including the sleep time). It will restart Explorer and reset the taskbar to default.



You need to pin the icons again. If you had added additional toolbars on the taskbar, you’d need to re-add them.

Related article: Fix The Gap That Appears At The Bottom Of Taskbar Icons


One small request: If you liked this post, please share this?

One "tiny" share from you would seriously help a lot with the growth of this blog. Some great suggestions:
  • Pin it!
  • Share it to your favorite blog + Facebook, Reddit
  • Tweet it!
So thank you so much for your support. It won't take more than 10 seconds of your time. The share buttons are right below. :)

Ramesh Srinivasan is passionate about Microsoft technologies and he has been a consecutive ten-time recipient of the Microsoft Most Valuable Professional award in the Windows Shell/Desktop Experience category, from 2003 to 2012. He loves to troubleshoot and write about Windows. Ramesh founded Winhelponline.com in 2005.

15 thoughts on “How to Reset Taskbar Settings to Windows Defaults”

  1. Thanks Ramesh!
    It took me the whole evening to find a solution
    My taskbar could be either set to left or right but not top or bottom for some reason
    This script did the job

    Windows 8.1

    Reply
  2. oh my, thank you so much. Autohide was not working suddenly on multiple monitors. No useful answers from Microsoft or elsewhere on the internet. Three hours later, I found your script. Worked perfectly! Thank you so much.

    Reply
  3. Thank you so much! Your script worked perfectly for my problem with a software developped by HP (HP Support Assistant)! I tried so many things but nothing worked except your script! Now the icon is fully removed from the taskbar!

    Reply
  4. Sorry, but your script did not help my issue. I had removed the Explorer.exe icon from my taskbar, and need to pin it back to the taskbar. I have tried a number of options (i.e., drag Explorer.exe, from C:\Window folder Start->Accessories\Windows Explorer + right click-/>Pin to Taskbar, etc.), but none of them work. I was hoping yours would do the trick, but alas no luck.

    If you have any other suggestions, I would appreciate receiving anything new.

    Thanks…

    Reply
  5. Thanks, couldn’t get it to go back down to normal size. Taskbar was taking up a quarter of my screen and I’m not a fan of auto hide. Only took me a second to find this fix though. It was right at the beginning of Google search. Good work. One would think Windows would have a setting for this. Thanks again.

    Reply
  6. Windows 11 Enterprise 21H2

    Did not work for me.. Issue is: Calendar/Time flyout not working in the system tray. Dual monitor. Right click over time/calendar shows two options:

    – Adjust Date and Time
    – Notifications Settings

    Also, this may help, I am not able to access the Notifications to the right of the date/calendar in the system tray.

    Reply
  7. Thanks a lot for the tool. Someone had some kind of web search nestled in the taskbar, apparently after an installation. I was thinking adware or something like that. I have tried everything. I ran AdwCleaner and Malwarebytes, checked browser extensions, checked running processes and services as well as installed programs, existing folders, even hidden ones. All of it did not help. Then after I ran the script, the web search disappeared from the taskbar. What exactly of it helped, I don’t know. Simply restarting Windows Explorer (explorer.exe) had not helped before.

    Reply

Leave a Reply