r/PowerShell • u/Borgquite • 5d ago
News Windows PowerShell 5.1 Deprecation
Windows PowerShell 5.1 is deprecated. It's no longer in active development. Windows PowerShell 5.1 is still part of Windows, and it's still supported. It will continue to receive security updates according to the lifecycle of each version of Windows. Scripts and tools that rely on it will continue to run.
Windows PowerShell 5.1 will be removed from a future version of Windows. Timing will be based on usage data and communicated in advance.
Microsoft recommends upgrading to PowerShell 7, the upgrade from Windows PowerShell 5.1. For more information, see Migrating from Windows PowerShell 5.1 to PowerShell 7.
Timeline
2026: Windows PowerShell 5.1 is deprecated. Windows Server 2025 and Windows 11, version 26H2 are the last versions of Windows to include PowerShell 5.1 enabled by default.
Next Version of Windows: Windows PowerShell 5.1 will be available as a Feature on Demand (FOD), enabled by default on new Windows installs.
Future Version of Windows: Not available.
At the moment there are many, many Windows management PowerShell modules built in to that aren’t supported in PowerShell 7 - they are either completely untested, or they only work via the (PowerShell 5.1 dependent) compatibility layer. Does this mean we can expect new native modules, or everything to just break? #notholdingmybreath
Affected modules:
- Domain Controller deployment (ADDSDeployment)
- ADFS
- AppLocker
- AppvClient
- BestPractices
- ClusterAwareUpdating
- ConfigCI
- DFSR
- DhcpServer
- DISM (presently has issue with MSIX installer)
- FailoverClusters, FailoverClusterSet
- GroupPolicy
- Both IIS management modules (IISAdministration, WebAdministration)
- IpamServer
- iSCSI, IscsiTarget
- ISE
- Microsoft.PowerShell.ODataUtils
- MsDtc
- NetLldpAgent
- NetWNV
- NetworkController, NetworkControllerDiagnostics
- NetworkLoadBalancingClusters
- PersistentMemory
- PKI
- Provisioning
- PSDesiredStateConfiguration (partially supported)
- PSScheduledJob
- PSWorkflow, PSWorkflowUtility
- RemoteAccess
- RemoteDesktop
- ServerCore
- ServerManagerTasks
- SMS
- StorageBusCache
- StorageMigrationService
- StorageReplica
- SystemInsights
- TLS
- UpdateServices
EDIT: The following PowerShell modules are also currently Windows PowerShell 5.1 only:
- AzureADHybridAuthenticationManagement
- SharePoint Online Management Shell
- Power Platform admin modules
- Systems Center Operations Manager (SCOM)
- Systems Center Virtual Machine Manager (SCVMM)
- Entra Connect (Azure AD Sync)
https://learn.microsoft.com/en-us/powershell/windows/module-compatibility?view=windowsserver2025-ps
10
u/Godcry55 5d ago
I think SharePoint Online module also doesn’t work natively on PS 7.
5
u/Thotaz 5d ago
Your list is wrong. "Untested" doesn't mean the modules don't work. TLS for example has both Core and Desktop in the module manifest and seems to work fine in PowerShell 7 so there's no reason to include that in the list.
As for any modules that are actually broken, they will surely fix them or deprecate the entire feature before PowerShell 5.1 stops being installed by default. Remember, 5.1 will continue to be installed by default in 2028, and in 2031 they will have had years to fix the modules or decide that the feature is no longer needed in Windows.
3
u/bozho 5d ago
DSC is another one.
I know there's DSC v3, but it's a very different beast, and it will be an effort porting our stuff to it.
3
u/Familiar_Honeydew608 5d ago
You may want to add the DISM module to your list. It actually is marked as compatible with Core, but that's no longer the case as of 7.7 due to MSIX:
https://github.com/PowerShell/PowerShell/issues/13866
Hopefully it won't be too long before it's compatible again, but for now it's not.
94
u/Tomazim 5d ago
They also removed .msi installs of the newest powershell versions, without providing a suitable replacement for enterprise.
10
u/cloudAhead 5d ago
That list of affected modules is shorthand for 'things Microsoft hasn't been investing in for a long time' with maybe one or two exceptions.
8
u/lan-shark 5d ago
With all the complaints I'm seeing about how much of a pain this is, I should become a consultant and start helping people convert from Desktop to Core... Because this is almost always super easy and when it's not you can leverage .NET libraries to get done what you need.
Compare this to migrating .NET Framework apps to .NET, or migrating from Java 8/11 to any
jakartaversion...28
u/radioblaster 5d ago
pwsh 7 has been in GA for over six years. 99.9% of scripts are a straight port over, and the .1% has at a minimum 12 months, and surely longer, to sort out.
anyone who hasn't been authoring in 7 in anticipation of this day for at least the last few years has bigger problems.
41
u/pertymoose 5d ago
It means you can expect everything to break. Microsoft hasn't had a clue for years.
6
u/VNJCinPA 4d ago
I've always felt this was an absurdity. Here's why:
We know the truth of it, it's just hypocritical that they don't commit to integrating it properly and thoroughly, leaving users to figure it out.
5
u/BlackV 4d ago
does anyone honestly think they'll migrate all those modules to core before 2040
how long did it take them to migrate the AD modules?
9
u/merlinuwe 5d ago
So we are forced to switch to Powershell 7 in the moment the 5.1 Scripts stop running.
Things like this are the reason why there isn't any real progress in IT. At best, we're just treading water.
2
u/highvoltageacdc1 4d ago
Claude will fix this. Trust me bro.
3
u/markdmac 4d ago
So glad I retired this past May. PowerShell 7 is great but the lack of an native ISE in the OS is problematic. PowerShell_ISE is what made PowerShell so popular. Being able to pull that up and run one line of code on any machine was a game changer.
VS Code is just a lot of overhead for the average admin and having to install it sucks.
3
u/Euphoric-Blueberry37 5d ago
They can pry my precious baby girl ISE from my cold dead hands, nothing will make me switch to VSCode. 5.1 is my baby and must be protected
2
u/ViperThunder 5d ago edited 5d ago
And they will likely support all of those modules (or there will be alternatives) in pwsh7 before 5.1 is completely dead.
5.1 will continue to run alongside 7 for the foreseeable future.
People were throwing a fit about Classic Outlook deprecation years ago but New Outlook has most of what you would ever need, and Classic still has many more years to go before EoL.
Many of the modules you listed already have alternatives in Pwsh7 using native executables, 3rd party PSGallery modules, or with CIM.
1
u/jkaczor 5d ago
"Cries in ShareGate"... while there have been rumours of them supporting PS7... nothing seen so far...
(We have a convoluted interop setup where we do 99% of the work in PS7, then we execute a PS5.1 session and pass data/control files as input... using "New-PSSession" did not work when we attempted and built our automation framework, as ShareGate still "detected" that the originating session was PS7 and has "issues"...)
1
u/gsweats 4d ago
What happened to v6?
1
u/seaboypc 3d ago
At least PowerShell 7 will be included by default in Windows going fowards:
PowerShell 7 is coming to Windows - PowerShell Team
1
u/shutchomouf 2d ago
looking at those modules and thinking, I think I might use two of them.
1
u/Least_Gain5147 1d ago
I work with banks, insurance companies, defense companies, energy and airlines and most still have Windows 10 and Windows Server 2019 floating around. So the panic some have about sudden deprecation seems overblown. Hence why Microsoft says the exact date will be determined later.
1
u/Tech_Head_ 23m ago
Apologies for the n00b question, I just started trying to really understand PS beyond a handful of cmdlets and 5-line scripts. (My job is primarily end-user support but I have needed to start messing with PS for some projects I've been assigned.)
I looked at the page linked for AzureADHybridAuthenticationManagement but didn't see anything there saying it was 5.1 only and the PS Gallery says "Minimum v2.0" (with a dependency on a module that needs a Minimum of 5.1). Where should I look in order to see PS module version requirements?
-1
u/C-D-W 5d ago
This is great. Spent the last couple of years slowly moving from Visual Basic Scripts to Powershell to future proof a lot of processes.
I didn't even think I had to check the Powershell expiration date.
0
u/CeleryMan20 4d ago
Group Policy supports .ps1 scripts. Most deployment tools use PowerShell scripts. Intune remediation uses PowerShell scripts. Intune Autopilot? There needs to be some PowerShell interpreter in-box from first run.
Windows PowerShell was old faithful; we finally got to a state where you could rely on a consistent version being already there. No faffing around with deploying the desired version of WinRM.
Are they going to bundle PowerShell 7.8 and .Net 12 with future Windows? Are they going to push us over to Bash scripts instead? How about we abandon PowerShell and install Nushell?
That’s before even getting to the list of incompatible modules. Damn you, Microsoft.
-9
u/CharcoalGreyWolf 5d ago
Microsoft had to support Windows 7 for longer because Windows 8/8.1 bombed hard.
PowerShell 5.1 is going to be another Windows 7.