Power Query Problems

How to Fix Power Query SharePoint Credentials Prompt in Excel

Algirdas JasaitisAlgirdas Jasaitis Nov 11, 2026 868 views

Question details

Users need to know how to properly prompt for and handle SharePoint credentials when an Excel macro refreshes Power Query data.

How to Fix Power Query SharePoint Credentials Prompt in Excel
Product
Excel
Device & OS
not provided
Scenario
Refreshing data stored in SharePoint using an Excel macro via Power Query.
Observed behavior
Power Query fails to authenticate to SharePoint, and the credentials dialog may be missing, invalid, or suppressed by the macro.
Before you start

Ensure you have a stable internet connection and that your organizational account has at least read access to the target SharePoint resource.

Solution 1Recommended

Manually Authenticate the Organizational Account

Test the refresh process without the macro to trigger the standard Power Query credentials dialog and sign in correctly.

By default, Power Query should automatically display a credentials dialog if it cannot authenticate to SharePoint. Isolating the refresh from the macro helps determine if the issue is with the credentials themselves.

1
Perform a manual refresh

Navigate to the 'Data' tab in the Excel ribbon and click 'Refresh All' without running your macro.

2
Select the account type

When the Power Query credentials dialog appears, select the 'Organizational account' option from the left-hand menu.

3
Sign in to SharePoint

Click the 'Sign in' button and enter your organizational email address and password associated with the SharePoint site.

4
Apply and connect

Click 'Connect' to save your credentials. The data refresh should now complete successfully.

Manually Authenticate the Organizational Account
Authentication Saved: Once you successfully sign in manually, Power Query will remember these credentials for future macro executions.
Free Microsoft Office alternative

Try WPS Office for Seamless Spreadsheet Management

If you want to avoid complex credential configurations and macro troubleshooting, WPS Office provides a lightweight, highly compatible, and user-friendly alternative for your daily spreadsheet needs.

  1. 1. Download WPS Office: Visit the official WPS website and download the free installation package for your operating system.
  2. 2. Install the software: Run the downloaded installer and follow the simple on-screen instructions to complete the setup.
  3. 3. Open your spreadsheets: Launch WPS Spreadsheets and open your existing Excel files directly to continue working seamlessly.
100% compatible with Microsoft Excel (.xlsx, .xls, .csv) formats.Free and lightweight design for faster data loading and processing.Familiar user interface requires no steep learning curve.Built-in advanced formulas and data visualization tools.
microsoft office alternative - wps office

Frequently Asked Questions

Why isn't Power Query prompting for SharePoint credentials automatically?

This usually happens if an Excel macro is intercepting the refresh process, or if 'Application.DisplayAlerts' is set to False in your VBA code, which suppresses the necessary authentication dialog box.

Which account type should I select for SharePoint in Power Query?

When the credentials dialog appears, you should always select the 'Organizational account' option and sign in with the work or school email address that has access to the SharePoint site.

How do I clear or change my existing Power Query credentials?

In Excel, go to the 'Data' tab, select 'Get Data', and click 'Data Source Settings'. Locate your SharePoint URL in the list, click 'Clear Permissions' or 'Edit Permissions', and try refreshing your data again to trigger a new prompt.