After updating to PowerShell 7.6.3, my shell startup time has increased dramatically. Loading the profile now averages about 10.7 seconds. Has anyone else noticed slower profile loading, or is something specific in my setup likely causing the delay?
4 Answers
I haven’t seen a general slowdown in profile loading. Startup time depends heavily on what the profile runs, so first try isolating the issue with `pwsh -NoProfile`. If that starts quickly, add timing output such as `(Get-Date).ToString('o')` around each profile command to find the expensive step. Also check `$env:PATH` and `$env:PSModulePath` for unavailable network or UNC locations, since those can introduce long delays.
Check whether your Documents folder, including the PowerShell profile directory, is being synchronized by OneDrive. Make sure the files are stored locally and marked as always available offline. Antivirus scanning can also cause a noticeable startup penalty, so testing on another machine or temporarily checking Defender exclusions may help identify that.
In one measured case, most of the delay came from profile commands rather than PowerShell 7.6.3 itself: importing Terminal-Icons took several seconds and initializing oh-my-posh took even longer. Caching the oh-my-posh initialization result and adding an antivirus exclusion brought cold-start performance back under control. Repeated launches were already much faster, suggesting caching or security scanning was involved.
The terminal host matters too. VS Code and other IDE terminals can use a different profile path and inject shell-integration code. Compare a normal console launch with `pwsh -NoProfile` and with your profile enabled to determine whether the delay comes from PowerShell itself, the profile, or the host.

I instrumented the profile and found the biggest costs were Terminal-Icons and oh-my-posh initialization. After caching the oh-my-posh setup and adding a Defender exclusion, startup improved substantially.