Power BI is turning 10, and we’re marking the occasion with a special community challenge. Use your creativity to tell a story, uncover trends, or highlight something unexpected.
Get startedJoin us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.
Hi everyone,
I'm currently facing an issue when trying to authenticate to Microsoft Fabric using the ms-fabric-cli tool. I've tried both interactive login using browser and service principal authentication, but in both cases I receive the following error:
I'm running the CLI from a PowerShell terminal inside Visual Studio Code.
Connection to login.microsoftonline.com timed out. (connect timeout=None)
I believe, that I do have the necessary permissions and access, as I'm able to:
Additionally, when attempting interactive login, the browser window doesn't even open — the process seems to hang before reaching that step.
Has anyone encountered a similar issue or have any suggestions on how to resolve this timeout error? Could it be related to network configuration, proxy settings, or something else specific to the CLI or Python setting?
Thanks in advance for any help or insights!
Solved! Go to Solution.
Hey @JiriSM ,
To troubleshoot this issue, here are few suggestions and steps you might try:
Check Proxy Settings:
The error you're receiving may be due to your network configuration, particularly if you're behind a proxy. Check whether your machine is behind a proxy and if so, ensure that it's properly configured to allow traffic to login.microsoftonline.com. You can configure the CLI to use a proxy by setting the HTTP_PROXY and HTTPS_PROXY environment variables. You can check your proxy settings in PowerShell using:
Get-Item -Path env:HTTP_PROXY Get-Item -Path env:HTTPS_PROXY
If they're set, try temporarily unsetting them or ensuring they point to the correct proxy server.
Network Configuration:
If your network restricts outbound internet access (e.g., firewall), ensure that access to login.microsoftonline.com is allowed. Check if any firewall rules might be blocking the connection to that endpoint.
Interactive Login:
If the interactive login doesn't open the browser window, ensure that your default browser is set up properly and that there are no browser-related issues preventing it from launching. You could try setting a different browser as the default or manually open the login URL in a browser if the process hangs.
Check for Python Configuration Issues:
The ms-fabric-cli tool depends on Python, so ensure that Python is correctly configured. Verify your Python version in powershell with:
python --version
Also, check if any environment variables related to Python (like PYTHONPATH) are set improperly.
CLI Version:
Ensure you're using the latest version of the ms-fabric-cli tool. There might have been bug fixes or improvements that could resolve your issue. You can check for updates using powershell:
pip install --upgrade ms-fabric-cli
Verbose Logging:
Run the ms-fabric-cli command with verbose logging enabled to gather more details about the error. This could give you additional insights into where the process is failing. You can typically enable verbose logging with a --debug or similar flag (depending on the tool).
Check Azure CLI Authentication:
If you're able to access APIs with PowerShell cmdlets, make sure you're also authenticated with Azure CLI (az login) before running the ms-fabric-cli tool. Sometimes the CLI tools might rely on Azure CLI authentication for some operations.
Verify Fabric CLI Permissions:
Even though you mentioned that you have the necessary permissions, ensure that your service principal or user account has sufficient permissions to authenticate and access the resources you're trying to reach.
For Detailed Informatin:
ms-fabric-cli Installation and Troubleshooting
Python Installation and Configuration
Azure Active Directory Authentication
If you found this solution helpful, please consider accepting it and giving it a kudos (Like) it’s greatly appreciated and helps others find the solution more easily.
Best Regards,
Nasif Azam
Hi @JiriSM,
As we haven’t heard back from you, we would like to follow up to see if the solution provided by the super user resolved your issue. Please let us know if you need any further assistance.
If our super user response resolved your issue, please mark it as "Accept as solution" and click "Yes" if you found it helpful.
Regards,
Vinay Pabbu
Hey @JiriSM ,
To troubleshoot this issue, here are few suggestions and steps you might try:
Check Proxy Settings:
The error you're receiving may be due to your network configuration, particularly if you're behind a proxy. Check whether your machine is behind a proxy and if so, ensure that it's properly configured to allow traffic to login.microsoftonline.com. You can configure the CLI to use a proxy by setting the HTTP_PROXY and HTTPS_PROXY environment variables. You can check your proxy settings in PowerShell using:
Get-Item -Path env:HTTP_PROXY Get-Item -Path env:HTTPS_PROXY
If they're set, try temporarily unsetting them or ensuring they point to the correct proxy server.
Network Configuration:
If your network restricts outbound internet access (e.g., firewall), ensure that access to login.microsoftonline.com is allowed. Check if any firewall rules might be blocking the connection to that endpoint.
Interactive Login:
If the interactive login doesn't open the browser window, ensure that your default browser is set up properly and that there are no browser-related issues preventing it from launching. You could try setting a different browser as the default or manually open the login URL in a browser if the process hangs.
Check for Python Configuration Issues:
The ms-fabric-cli tool depends on Python, so ensure that Python is correctly configured. Verify your Python version in powershell with:
python --version
Also, check if any environment variables related to Python (like PYTHONPATH) are set improperly.
CLI Version:
Ensure you're using the latest version of the ms-fabric-cli tool. There might have been bug fixes or improvements that could resolve your issue. You can check for updates using powershell:
pip install --upgrade ms-fabric-cli
Verbose Logging:
Run the ms-fabric-cli command with verbose logging enabled to gather more details about the error. This could give you additional insights into where the process is failing. You can typically enable verbose logging with a --debug or similar flag (depending on the tool).
Check Azure CLI Authentication:
If you're able to access APIs with PowerShell cmdlets, make sure you're also authenticated with Azure CLI (az login) before running the ms-fabric-cli tool. Sometimes the CLI tools might rely on Azure CLI authentication for some operations.
Verify Fabric CLI Permissions:
Even though you mentioned that you have the necessary permissions, ensure that your service principal or user account has sufficient permissions to authenticate and access the resources you're trying to reach.
For Detailed Informatin:
ms-fabric-cli Installation and Troubleshooting
Python Installation and Configuration
Azure Active Directory Authentication
If you found this solution helpful, please consider accepting it and giving it a kudos (Like) it’s greatly appreciated and helps others find the solution more easily.
Best Regards,
Nasif Azam
This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.
Check out the June 2025 Power BI update to learn about new features.
User | Count |
---|---|
59 | |
33 | |
27 | |
25 | |
24 |
User | Count |
---|---|
63 | |
53 | |
31 | |
24 | |
20 |