Register-PnPManagementShellAccess is not recognized

Are you getting the error “register-pnpmanagementshellaccess is not recognized” while using PnP PowerShell? I will show you how to fix this error.

Register-PnPManagementShellAccess : The term ‘Register-PnPManagementShellAccess’ is not recognized

Recently, I was using PnP PowerShell to connect to SharePoint Online. While running the below command, I received the error:

Register-PnPManagementShellAccess

The complete error message looks like the below:

Register-PnPManagementShellAccess : The term ‘Register-PnPManagementShellAccess’ is not recognized as the name of a
cmdlet, function, script file, or operable program. Check the spelling of the name, or if a path was included, verify
that the path is correct and try again.

You can see the screenshot below:

Register-PnPManagementShellAccess is not recognized

Now, let me tell you a few things I debug.

I installed PowerShell’s latest version (PowerShell 7.4.1 or more), but when I ran the $PSVersionTable cmdlet, it still showed me PowerShell version 5. You can see the screenshot below:

register-pnpmanagementshellaccess is not recognized error in pnp powershell

Solution: register-pnpmanagementshellaccess not working

Here is what I did to fix this error.

Open the PowerShell 7 command prompt. To do so, click on Start -> All apps and then choose PowerShell 7 (x64) like in the below screenshot.

the term 'register-pnpmanagementshellaccess' is not recognized

This will open the PowerShell 7, and you can run the command below.

Register-PnPManagementShellAccess

Now, the error will not come. You can see this in the screenshot below:

register-pnpmanagementshellaccess not working

I hope this will fix the register-pnpmanagementshellaccess not working issue that you might receive while working with PnP PowerShell. You can follow the steps and let me know if you can fix the error “register-pnpmanagementshellaccess is not recognized“.

You may also like:

>