If you want to install a preview version:
Verify installation:
The PSVersion row will show your current version (e.g., 5.1 or 7.x). 2. Update PowerShell via WinGet update powershell command windows 11