How to Import and Clean Data in Excel with Copilot and Power Query
Importing files into Excel is easy. Keeping the data clean every month is harder. This guide shows how to import and clean data in Excel with Power Query, use Copilot as a helpful assistant and verify every important change. The workflow suits teams working with CSV and workbook exports in the US, UK, Canada and Australia.

Why imports need a repeatable cleanup process
A downloaded CSV may have extra header rows, missing values, mixed date formats or columns that change order each month. Copying and pasting directly into a report can quietly break formulas. Power Query lets you build a repeatable import process, while Copilot can help plan the cleanup, explain formulas and review results. Treat Copilot as a helper and Power Query’s applied steps as the record of what changed. This distinction matters when someone needs to audit a report later.
What Power Query does
Power Query is Excel’s Get & Transform feature. It connects to files and other sources, previews data and applies a sequence of transformations. Common steps include choosing columns, filtering rows, trimming text, changing data types and merging tables. You can inspect the Applied Steps pane, edit individual steps and refresh the query when the next file arrives. Some connectors and features differ by Excel platform, account and organization policy. Microsoft’s Power Query documentation is the best reference for the current interface.
Choose a clear source and output
For a beginner example, use a folder of monthly sales CSV files. Each file contains Order ID, Date, Region, Product and Amount. Keep the original files unchanged in a read-only source folder. Create a separate workbook for the query and an output sheet for the cleaned table. Decide whether all files should be appended, whether different formats need separate queries and which columns are required. If files include personal data, use an approved location and avoid uploading sensitive information to unapproved AI tools.
Step 1: Import a CSV or workbook
In a supported version of Excel, open Data, choose Get Data and select the appropriate source, such as Text/CSV or an Excel workbook. Preview the delimiter, encoding and column names. If a CSV uses semicolons but Excel guesses commas, correct that before loading. For a recurring folder of similarly shaped CSV files, explore the folder connector. Do not combine files until you have checked whether they share the same headers and meaning. Choose Transform Data to open Power Query Editor before loading into the report.
Step 2: Promote and rename headers
Some exports begin with a report title or date line above the real header. Remove those top rows only after confirming where the table begins. Then promote the correct first row to headers. Rename columns to stable names such as OrderDate and NetAmount. This makes later transformations easier to understand. Avoid using a heading like “November Sales” for a permanent column name because it will change the next month. Copilot can suggest a naming scheme, but you should keep the names consistent across refreshes.
Step 3: Set data types intentionally
A common error occurs when a date is guessed using the wrong locale. For example, 07/08/2026 can mean July 8 or August 7. Use Change Type with Locale when the source format needs explicit interpretation. Convert amounts to a numeric type only after removing nonnumeric text according to a documented rule. Keep region or product identifiers as text if leading zeros matter. Review any conversion errors instead of removing them immediately. A wrong data type can alter totals or join keys.
Step 4: Trim and standardize text
Power Query provides transformations that trim extra spaces and clean text. Check whether capitalization differences are meaningful in identifiers. For categories, use an approved mapping table rather than a series of guesses. For example, “UK,” “U.K.” and “United Kingdom” may map to one reporting category, while “CA” is ambiguous without context. Do not automatically standardize addresses, legal names or SKU codes. A repeatable map with examples and an owner is safer than silent replacements.
Step 5: Find duplicates and missing rows
Power Query can keep or remove duplicate rows, but you must choose the columns that define a true duplicate. Two orders may share a customer, date and amount yet still be separate purchases. Compare Order ID, transaction type and status before removing data. For missing values, ask whether null means unknown, not applicable or zero. Use filters and a separate exceptions query to review records that need manual attention. Keep counts before and after each major transformation.
Step 6: Combine files without mixing months
When you import a folder, check that each source file has a reliable date or period. If the sales table lacks this information, keep the filename as a provenance column before combining files. Inspect the sample-file transformation generated by Power Query. A future export may gain a new column or change a heading, which can break a refresh. Test with at least two months of source files and one deliberately unusual file. Make sure records are not duplicated because an old input was accidentally imported twice.
Step 7: Load and refresh the cleaned table
Once the query steps look correct, choose Close & Load or the relevant load destination. Keep a separate worksheet for manual comments instead of typing them into the query output. On the next reporting cycle, add the new source file and refresh. Review any errors, missing columns and row-count changes. Do not assume refresh means validation: it only means the configured steps ran. Set a simple control total and compare it with the source system each time.
Where Copilot adds value
Copilot can help explain Power Query concepts, suggest a data-cleaning checklist or formulate an Excel calculation to validate the output. In supported Excel experiences, it may also assist with table changes. Give it precise descriptions of the columns and the desired rule. Ask it to list assumptions before giving a solution. Do not paste confidential rows into a general chat. If you use generated Power Query M code or formulas, test them in a copy and verify each step against official documentation.
A realistic small-business example
Imagine a consultant receiving invoices from three systems. One sends a CSV with US-style dates, another exports an Excel table with UK-style dates, and a third uses different column names. Create one staging query per source, standardize the columns and date conventions, then append the normalized tables. Add a SourceSystem field so every record can be traced back. Compare invoice counts and total amounts to each original export. This process is more reliable than combining everything into one worksheet and asking Copilot to “make it clean.”
Fix common Power Query errors
A “column not found” error may mean the source export renamed a header. A type-conversion error may indicate a date format, currency symbol or unexpected text. A privacy-level warning may reflect the way sources are combined. Review the exact message and trace it to the Applied Step where the error first appears. Avoid deleting all error rows just to make the query finish. Keep an exception report and decide whether the source system or transformation needs repair.
Validation checklist
Before publishing a report, compare source and output row counts, duplicate keys, blank required fields, totals and distinct categories. Check a handful of records from each source file. Verify that a refresh on unchanged inputs produces unchanged results. Save the workbook version and document which source files were included. If a stakeholder needs a different rule, update the query in a controlled way and rerun the test. This discipline is what turns a one-time cleanup into a dependable workflow.
Frequently asked questions
Can Copilot import Excel files for me? Supported Excel Copilot experiences can assist with workbook data and import-related tasks, but Power Query remains a clear way to manage repeatable external-data transformations.
Should I use Power Query or formulas? Use Power Query for repeatable imports and shaping. Use formulas for calculations that belong in the workbook’s analysis layer.
Will Power Query delete my source files? Normal query transformations operate on imported data; still keep original exports and verify your process before relying on it.
Can I refresh automatically? Supported Excel and Power Automate workflows may schedule parts of the process, subject to connector and licensing rules.
How do I avoid wrong date formats? Set the source locale explicitly and test dates that expose day/month ambiguity.

Official sources and related reading
- Microsoft: About Power Query
- Microsoft: Import data from sources
- Microsoft: Duplicates in Power Query
- Microsoft: Data types
Related GetTechDose guides: cleaning messy Excel data and automating repetitive Excel tasks.
