How to resolve IDCRL exception for SharePoint Online when using PnP PowerShell

This blog post helps you to resolve the IDCRL error, when we are trying to connect SharePoint Online using PnP PowerShell

I have run the below PnPPowerShell command to connect the SharePoint Online

PS: > $cred = Get-Credential
PS: >  Connect-PnPOnline –Url https://<tenant> –Credential $cred

I have received the below error message.

Connect-PnPOnline : Identity Client Runtime Library (IDCRL) could not look up the realm information for a federated sign-in

I just verified the code once again and everything seems fine for me. But it not works.

So, I have re run the code and now the site is connected. How come???

In the code, we have called Get-Credential to ask the coder to enter credentials to connect SharePoint Online. Now, I have entered wrong credentials. Wow, I have received the same error message.

IDCRL Exception
IDCRL Exception

Root Cause:

So, if we received this issue. First, we have to check whether we have entered the correct credentials.


Entering the correct credentials, will solve this issue.

Happy troubleshooting :)

Shantha Kumar
Shantha Kumar
Articles: 270

One comment

Leave a Reply

Your email address will not be published. Required fields are marked *