How To Resolve IDCRL Exception For SharePoint Online When Using PnP PowerShell

I have run the below PnPPowerShell command to connect to SharePoint Online.
  1. PS: > $cred = Get-Credential  
  2. PS: > Connect-PnPOnline –Url https://<tenant>.SharePoint.com –Credential $cred  
Instead of connecting, 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 returns the error. 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 the credentials to connect to SharePoint Online. Here, I have entered the wrong credentials. Wow, I have received the same error message.



Root Cause


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

Solution

Entering the correct credentials will solve this issue. Are you still facing the issue, check whether the issue is related to the configuration authentication.

Happy troubleshooting :)
Ebook Download
View all
Learn
View all