Yes. In Excel for Microsoft 365 on Windows, you can open a CSV file directly or import it with Data > Get Data > From File > From Text/CSV. Use the import route when you need to control how Excel reads columns, dates, delimiters, or text such as postal codes with leading zeros.
What a CSV file contains
CSV stands for comma-separated values. It is a plain-text format for storing rows of data: each line generally represents a row, and commas separate the values in that row. A simple file might contain a header line followed by entries such as a customer name, city, and postal code. The format is widely used because many databases, websites, and business applications can export or accept it.
Despite its name, a CSV file does not always use commas. Some systems use semicolons or tabs as separators, often because commas are used as decimal marks in local number formats. CSV also does not preserve the workbook features people associate with Excel: it cannot store multiple worksheets, cell formatting, charts, or formulas as working formulas. It stores text values in a flat table-like structure.
Excel can display a CSV as a familiar grid, but the file itself remains plain text until you save it in an Excel workbook format. That distinction matters if you want to preserve formatting, add worksheets, or keep Power Query settings for future use.
Two ways to bring a CSV into Excel
For a quick look, open Excel and choose File > Open, then browse to the CSV. You can also open the file from File Explorer if Excel is the application associated with .csv files. Excel places the data in a worksheet, using its current regional and import defaults to interpret the content. This is convenient for a small, uncomplicated file, but gives you less opportunity to check how values are being interpreted before they appear.
For more control, import the file from Excel’s Data tab. In Microsoft 365 for Windows, choose Data > Get Data > From File > From Text/CSV, select the file, and inspect the preview. Depending on the dialog and options available, you can choose a delimiter and review the detected data types before loading. Choose Transform Data if you want to inspect or adjust the data in Power Query first, or choose Load to put it into a worksheet.
In Excel for Mac, CSV files can also be opened directly. Power Query import availability and labels can vary by Excel version; in supported versions, look under Data for Get Data or the Power Query import options and select Text/CSV. Excel for the web can open CSV files stored in OneDrive, but its import and transformation controls are not identical to the Windows desktop app. If a particular setting is important, use the desktop import preview and verify the result.
Import with Power Query, step by step
Power Query is Excel’s data import and transformation tool. It is useful when a CSV needs cleanup, when you want to specify column types, or when you expect to load an updated version of the same source later. A typical Windows workflow is:
- Open the workbook where you want the imported data, or create a new workbook.
- Choose Data > Get Data > From File > From Text/CSV, then locate and select the CSV.
- Review the preview. Check that the columns are split correctly and that the first row is treated as headers if the file has column names.
- Set or review the delimiter and data types. For identifiers, codes, or values that must remain unchanged, choose Text rather than allowing Excel to interpret them as numbers or dates.
- Select Transform Data to make adjustments in Power Query, or select Load to bring the previewed data into Excel.
In the Power Query Editor, you can rename columns, remove unwanted rows, change data types, and filter records before loading. When you finish, use Home > Close & Load to return the results to Excel. The exact choices shown can depend on the file and Excel build, so check the preview rather than assuming automatic detection is correct.
For example, a sales export might have columns for Order ID, Date, Region, and Amount. You might set Order ID to Text so a value such as 000482 remains intact, set Date to a date type after confirming the date order, and set Amount to a number type. This makes the data easier to sort and analyze while avoiding unwanted changes to the identifier.
Choose the right delimiter and text encoding
If every field appears in one Excel column, Excel may not have recognized the separator. Reimport the file through Data > Get Data > From File > From Text/CSV and choose the delimiter that matches the source. Common choices include comma, semicolon, tab, and a custom character. The preview should show each field in its own column before you load.
Quoted fields are another reason a CSV may look confusing in a text editor. A field containing a comma can be enclosed in quotation marks so the comma is treated as part of the value rather than a separator. For example, a record may contain a city-and-state field written as one quoted value. Well-formed CSV readers recognize this convention, but malformed quotes or inconsistent rows can produce unexpected splits. If the preview is wrong, check the source file’s structure and delimiter settings.
Encoding determines how text characters are represented. If names or other non-English characters appear as question marks or garbled symbols, the file may be using an encoding Excel did not detect as expected. In the import preview, review the file origin or encoding option when available and select the appropriate encoding, often UTF-8 for modern exports. If you are unsure, compare a few accented or non-Latin characters with the original system before loading the full dataset.
Prevent common data changes
Excel tries to recognize dates, numbers, and other values, but automatic interpretation can alter data that only looks numeric. This is one of the most common CSV import problems. Decide whether each column represents a quantity that can be calculated or an identifier that must be preserved exactly.
- Leading zeros: A postal code such as 00421 or a product code such as 00073 may be converted to 421 or 73 if read as a number. Import the column as Text to retain the zeros.
- Long identifiers: Excel numeric cells preserve only 15 significant digits. A long account or tracking number can lose precision if Excel treats it as a number. Import identifiers as Text.
- Dates: A value such as 04/05/2026 can mean April 5 or May 4, depending on date conventions. Check the source’s regional format and use the appropriate locale or type settings when importing.
- Decimal and thousands separators: Values such as 1,25 or 1,250 may be interpreted differently under different regional settings. Confirm the intended decimal mark and number format before doing calculations.
- Blank cells and uneven rows: Missing fields may be legitimate, but rows with too few or too many separators can indicate a damaged or inconsistent export. Compare suspicious rows with the source system.
After loading, spot-check representative values against the original CSV, especially codes, dates, and amounts. Sorting or filtering can expose problems that are easy to miss in a quick visual scan. If the data will feed a report or a business process, verify column types and totals before relying on it.
Refresh, save, and share the result
When you use Power Query, Excel can retain a connection to the source file and the steps used to transform it. If the CSV is replaced with a newer export at the same location, you can refresh the query from the Data tab, provided the source path is still valid. Refreshing reruns the saved transformation steps; it does not guarantee that a changed file has the same columns or structure, so review the results after a source change.
To keep the imported data as an Excel workbook, choose File > Save As and select Excel Workbook (.xlsx). This preserves worksheets and workbook features. If you save as CSV instead, Excel warns that some workbook features are not compatible; a CSV normally stores only the active sheet’s cell values in a text format. Keep the .xlsx copy if you need formatting, multiple sheets, or query settings. Retain the original CSV as well if you need an unchanged source record.
Safety and reliability considerations
A CSV is plain text, but opening it in a spreadsheet does not make every value harmless. Files from unknown or untrusted sources can contain content that spreadsheet software interprets as a formula, particularly values beginning with characters such as an equals sign. Do not treat a CSV as safe just because it has no macros. If the file is unexpected, verify its source and inspect suspicious cells before using or redistributing it. For sensitive data, follow your organization’s handling rules and avoid placing confidential information in a workbook that will be shared broadly.
Also consider the size of the file. An Excel worksheet supports up to 1,048,576 rows and 16,384 columns. A CSV with more rows than a worksheet can hold will not fit into a single sheet in full. For larger datasets, use a database or another data tool, or use Power Query and the Data Model where appropriate, rather than assuming that loading to a worksheet will preserve every record.
When another approach makes sense
Opening the CSV directly is a sensible shortcut when the file is small, consistently formatted, and contains ordinary text and numbers. Power Query is a better fit when you need to control types, combine or clean data, or repeat the same import after receiving new exports. If the source system offers an .xlsx export and you need workbook formatting or multiple sheets, that may save conversion work. If it offers only CSV, import it and save a separate .xlsx workbook for ongoing analysis.
For a one-time task, you can also copy and paste text into Excel, but that is not necessarily more reliable: separators may not split into columns as intended, and automatic conversions can still happen. For recurring or high-volume work, use a repeatable import process and document the expected column names, formats, and source location.
Frequently Asked Questions
Can I import a CSV into an existing Excel workbook?
Yes. Open the workbook, use Data > Get Data > From File > From Text/CSV, and load the result to a worksheet. In the load options, choose where the table should go if Excel offers that choice. Check that the destination area is clear so existing data is not overwritten.
Why does my CSV open in one column?
Excel may not have detected the file’s delimiter. Import it through the Data tab and select the separator shown in the source, such as comma, semicolon, or tab. Check the preview before loading to confirm the fields are separated correctly.
How do I keep leading zeros in a CSV?
Import the affected column as Text in the preview or Power Query Editor. If Excel has already removed the zeros, changing the cell format afterward may not restore them; reimport from the original CSV with the column set to Text.
Can Excel automatically update data from a CSV?
A Power Query import can be refreshed from its source file. If the file is moved, renamed, or changed in structure, the query may need its source path or transformation steps updated. A CSV opened directly is not automatically a refreshable query just because it was opened in Excel.
Will a CSV keep my Excel formatting and formulas?
No. CSV stores plain text values in a delimited layout, not Excel workbook formatting, multiple sheets, or working formulas. Save the result as .xlsx when you need those workbook features.
Related
- ISERROR in Excel: How It Works and When to Use It
- ISBLANK in Excel: Examples and How It Works
- ISNUMBER in Excel: Check Whether a Cell Holds a Number
Try it: the Date Difference Calculator: days, months, years and weekdays between two dates, with the DATEDIF formulas.
More in How-to basics
- Google Sheets Calendar: Create and Customize Your CalendarTo create a calendar in Google Sheets, enter a year and month, then use a date formula to…
- Add to a Data Validation List in Excel: Step-by-StepTo add an option to an Excel drop-down list, select a cell that uses the list, open Data…
- Creating a Signature in Outlook: Steps and TipsTo create a signature in Outlook, open the signature settings for your version, choose New, write and format…
- CSV File to Excel Converter: Convert Without Data LossTo convert a CSV file to an Excel workbook in Microsoft Excel for Microsoft 365 on Windows, select…
- Lock Cells in Google Sheets: How Cell Protection WorksYes. In Google Sheets, use Data > Protect sheets and ranges to restrict editing of selected cells or…
- Excel Max Row Limit: Rows, Columns, and WorkaroundsIn Microsoft Excel for Microsoft 365, a worksheet can contain a maximum of 1,048,576 rows. That limit applies…
Sources: Function behaviour and menu paths: Microsoft Support documentation for Excel. Method & sources
Spotted an error in this guide? Let us know.