In Excel for Microsoft 365 on Windows, open the Power Query Editor from Data > Get Data > Launch Power Query Editor. To edit a query you already have, choose Data > Queries & Connections, then double-click the query or right-click it and select Edit.
Open the editor from the Data tab
The editor is a separate window from the main Excel worksheet. You can open it even if you have not selected a cell or created a query yet. In Excel, go to the Data tab, open Get Data, and select Launch Power Query Editor. The editor opens with no query selected if there is not an existing query to display.
Depending on your Excel build and ribbon layout, the command may appear in the Get & Transform Data area of the Data tab or under the Get Data menu. If the ribbon is narrow, some commands may be grouped into a dropdown. Look for the Get Data command rather than searching for a separate Power Query application: Power Query is built into Excel.
Once the editor opens, you can start bringing in data with Home > New Source. Choose a source, such as a workbook, text file, or database, and follow the prompts. Excel may first show a Navigator window so you can choose a table or sheet before opening the selected data in the editor.
Open and edit an existing query
If you have already imported or transformed data, editing its query is usually the quickest way into the editor. In the workbook, select Data > Queries & Connections to open the pane, which lists queries associated with the file. Double-click a query to open it, or right-click its name and choose Edit. The editor then displays that query and its current transformation steps.
You can also find a query through the worksheet table it loads. Right-click a cell in the output table and look for the option to edit the query; the wording and availability can vary with the table and Excel build. The Queries & Connections pane is the more dependable route, especially when a query loads only as a connection and therefore has no visible output table.
Editing a query does not mean that you are editing the original file or database. It changes the instructions Excel uses to retrieve and transform data when the query runs. To change the source itself, you would need to edit that source outside Excel or change the query’s source settings.
Open Power Query from a table or range
If the data is already in the workbook, selecting it first is often the most practical option. Click a cell inside a contiguous range of data, then choose Data > From Table/Range. Excel creates a query from that range and opens it in the editor. If the range is not already an Excel table, Excel asks whether to create one; confirm that the selected range is correct and indicate whether it has headers.
This route is useful for cleaning a pasted report, standardizing columns, or reshaping data before loading a clean version back to a sheet. For example, a monthly report might contain a title row, blank lines, and inconsistent date formats. In Power Query, you can remove the title and blank rows, promote the correct row to headers, and set the date column’s type before loading the result.
- Use From Table/Range when the source is a range or table in the current workbook.
- Use Get Data when the source is a separate file, database, or another supported service.
- Use Queries & Connections when your aim is to reopen a query that already exists.
What the Power Query Editor does
Power Query is Excel’s data-import and transformation tool. The editor lets you prepare data through a sequence of recorded operations, called Applied Steps, rather than manually repeating the same cleanup in cells every time new data arrives. Common operations include removing columns, filtering rows, splitting text, combining files, changing data types, and grouping records.
The editor generally shows a preview of the data, a ribbon of transformation commands, and a pane listing the query’s steps. Selecting a step lets you inspect the result at that point in the process. You can change or remove steps, but later steps may depend on earlier ones. If a later step refers to a column that has been renamed or deleted, for example, the query may show an error until you adjust the affected step.
The preview is not necessarily the full dataset. Power Query may use a sample or preview to display results, particularly for large sources. The preview helps you build and inspect transformations; the final output is determined when Excel applies the query to the data. A query can also combine information from more than one source, provided the sources and credentials are supported in your Excel environment.
Choose how the query should load
When you finish editing, choose Home > Close & Load to apply the query using its current load settings. To choose a destination or output style, use the dropdown beside Close & Load and select Close & Load To. The available choices depend on the query and workbook, but commonly include loading results to a worksheet table or creating a connection without placing the results in a sheet. Some workflows also let you add results to the Excel Data Model.
These choices affect where results appear, not whether the transformations are saved. A connection-only query can be useful as an intermediate step: another query can use it, or it can be refreshed without displaying a separate table. By contrast, a worksheet table is convenient when you want to inspect, chart, or reference the results directly. Loading a large result to a worksheet can take time and use substantial workbook space, so consider whether every intermediate result needs its own visible table.
After loading, use Data > Refresh All to rerun workbook connections and queries, or refresh an individual query from the Queries & Connections pane. Refreshing repeats the source and transformation process; it does not simply recalculate worksheet formulas. If the source file has moved, access has changed, or its structure is different, a refresh may fail or produce different results.
Windows, Mac, and Excel for the web
The steps above are for Excel for Microsoft 365 on Windows. Power Query is also available in supported versions of Excel for Mac, but available connectors and features can differ from Windows, and the ribbon layout or command wording may not match exactly. If you do not see the same command, check that Excel is updated and consult the Data tab’s import options for your installed version. A query created with a Windows-only connector or feature may not be fully editable or refreshable on another platform.
Excel for the web has Power Query capabilities for supported accounts and scenarios, but its editing and connector support are not identical to the Windows desktop application. Availability can depend on the Microsoft 365 plan, organizational settings, and source type. If you cannot find an editor command in the browser, open the workbook in desktop Excel and check the Data tab there. Avoid assuming that a query that can be viewed or refreshed online can also be fully edited online.
Common problems when opening the editor
- Get Data is not visible: Maximize the Excel window and inspect the Data tab for a collapsed group or dropdown. Ribbon customization can also hide commands; check Excel’s ribbon settings or use the Queries & Connections pane if you only need to edit an existing query.
- The query list is empty: The current workbook may not contain queries. Select a data range and use Data > From Table/Range, or start a new connection through Get Data.
- Edit is unavailable: You may have selected a worksheet cell or connection that is not an editable Power Query query. Confirm the item in the Queries & Connections pane and check that the workbook is not opened in a restricted or read-only state.
- The editor opens but shows an error: Inspect the Applied Steps list and select the first step showing an error. Common causes include a renamed source column, a moved or unavailable file, expired credentials, or a changed source layout.
- A source asks for credentials: Follow Excel’s prompt and select the appropriate authentication method for that source. For work or school data, access may be governed by your organization; do not enter credentials into an untrusted workbook or share them in query text.
If a command appears to be missing, first identify whether you are using Windows desktop, Mac, or a browser, and check your Excel update channel and license. Power Query features can change over time, and administrators can restrict connected services. Those differences are more likely explanations than a need to install a separate Power Query add-in for current Excel.
Power Query versus worksheet formulas
A common misconception is that Power Query is simply another place to enter Excel formulas. It is better understood as a repeatable data-preparation process. A worksheet formula calculates values in cells, often as part of a live grid of formulas and references. A Power Query transformation is saved as a step and is rerun when the query refreshes.
Use formulas when you need calculations that respond immediately to worksheet changes or interact directly with other cells. Consider Power Query when you repeatedly import, clean, combine, or reshape source data and want to apply the same process again after the source changes. The two approaches can work together: load a cleaned query result into a table, then use ordinary formulas, PivotTables, or charts to analyze it.
Frequently Asked Questions
Where is Power Query in Excel?
In Excel for Microsoft 365 on Windows, look on the Data tab. Open Get Data to launch the editor, or choose Queries & Connections to find and edit an existing query.
Can I open Power Query without selecting a data range?
Yes. Choose Data > Get Data > Launch Power Query Editor to open the editor, then use Home > New Source to select a data source. Select a range first only when you want to create a query from that workbook data.
How do I edit a Power Query in Excel?
Open Data > Queries & Connections, then double-click the query or right-click it and choose Edit. Make the changes in the editor and choose Close & Load to apply them.
Does opening Power Query change my original data?
No. Transformations are applied to the query’s result, not written back to the original source file or database. Excel loads the transformed output to the destination you choose when you close the editor.
Why can’t I see Launch Power Query Editor?
Check the Data tab’s Get Data menu and make sure the workbook is open in desktop Excel. The command can be in a collapsed ribbon group, and platform, update, license, or organization differences can affect what is available. For a query that already exists, try the Queries & Connections pane.
Related
- Excel Not Responding? Causes and Fixes
- How to Enter a Page Break in Excel and Control Printing
- Excel Data Validation Lists Based on Criteria
Try it: the Date Difference Calculator: days, months, years and weekdays between two dates, with the DATEDIF formulas.
More in How-to basics
- Excel Data Validation: Copy Rules Quickly and SafelyTo copy only data validation in Excel for Microsoft 365 on Windows, copy a cell that has the…
- How to Create CD Labels in WordTo create CD labels in Word, download the template for your exact label sheet, open it in desktop…
- How to Turn On Circular Reference Iteration in ExcelIn Excel for Microsoft 365 on Windows, turn on circular-reference calculation by going to File > Options >…
- Adding a Dropdown in Google SheetsTo add a dropdown in Google Sheets in a web browser, select the cell or cells, choose Insert…
- Google Sheets IF Function: Syntax, Examples, and TipsThe Google Sheets IF function checks whether a condition is true and returns one value if it is,…
- Google Sheets Auto Sum: How to Total a Column AutomaticallyTo auto sum a column in Google Sheets, select the cell where you want the total, choose the…
Sources: Function behaviour and menu paths: Microsoft Support documentation for Excel. Method & sources
Spotted an error in this guide? Let us know.