Windows Server: List all installed Roles and Features using PowerShell

If you install Roles and Features with PowerShell, Install-WindowsFeature is your friend. Get-Windowsfeature gets information about installed or available Server Roles. This blog post shows you how to get a list of all installed Roles on Windows Server 2012 or Windows Server 2016.

First of all, I want point out that there is a newer blog post that enables you to retrieve all server roles from all servers. More here: List all Server Roles from all Windows Servers with PowerShell


Running without parameters, Get-WindowsFeature gets information about all Server Roles and Features. We are looking for the attribute installstate. Possible values are: Installed, Available, Removed.


List all installed Features and Roles

Let´s move on. I am logged on Server03, which is a Member Server of my Domain. I search for all installed Roles on the localhost.

Get-WindowsFeature | Where-Object {$_. installstate -eq "installed"} | Format-List Name,Installstate | more


List all roles and Features on a Remote Host

As  mentioned, I am logged on Server03. Let´s find all installed Roles and Features on the remote computer dc01. Server03 and dc01 are in the same domain. I use Get-WindowsFeature with the parameter -ComputerName.

Get-WindowsFeature -ComputerName dc01 | Where-Object {$_. installstate -eq "installed"} | Format-List Name,Installstate | more


See also

For installing and listing Windows Server Roles and Features you can also establish a PowerShell Remote Session, which i described in this article: How to configure Trusted Hosts for PowerShell Remote Sessions.

12 replies »

  1. Why don’t use this simple command, instead your last command:
    Get-WindowsFeature -Name web-* | Where installed


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.