This topic describes how to connect Tableau to a Microsoft Excel file and set up the data source. Tableau can connect to .xls and xlsx files.
Click Connect to Data.
On the Connect page, click Microsoft Excel, select the Excel workbook you want to connect to, and then click Open.
To connect to the Excel file using the Microsoft Jet-based connection, in the Open dialog box, click the Open drop-down menu, and then select Open with Legacy Connection. The data source page displays.
On the data source page, do the following:
(Optional) Click the default data source name
at the top of the page, and then type a unique data source name for use
If your Excel file has one table, click Go to Worksheet to start building the view.
Alternatively, drag additional tables to the join area and use conditions to join them. You can choose to combine tables or use Custom SQL when you are working with multiple tables. You can also add joins later.
You can also connect to a named range the same way you connect to a worksheet. Named ranges are created in Excel by highlighting a range of cells and then selecting Define Name on the Formulas tab.
You can connect to multiple Excel worksheets at the same time as long as each worksheet has a unique connection name.
- (Optional) Click the default data source name at the top of the page, and then type a unique data source name for use in Tableau.
Optional SettingsYou can set the following options before building the view.
Set Excel table optionsIn the join area, hover over the table name until the gear icon displays, click the icon, and then specify whether the data includes field names in the first row. These names will become the names of the fields in Tableau. If column names are not included, they will be automatically generated by Tableau. You can rename the fields later.
Preview the data and change data types
The first 10,000 rows of the data in the data source is automatically displayed below the join area. If you add tables, remove tables, or make changes to the join conditions, the preview updates. You can also do the following in the preview area:
Change the data type of a column by clicking the data type icon.
Rename or hide a column by clicking the column header drop-down menu and selecting the respective option.
Connect live or use an extract
At the top of the data source page, select a live or extract connection to the data source. If you choose to take an extract, the Edit link displays allowing you to set up filters that define a subset of the data that you want to include in the extract.
Add data source filtersAdd data source filters to restrict the visibility and use of the fields in the data source.
Additional InformationAn example of a Microsoft Excel data source is shown below.
Note: If the Excel file contains columns that are more than 254 characters wide, Tableau is not able to use these fields for workbooks that were created before Tableau Desktop 8.2 or use the legacy connection. Either remove the columns, modify them to fit within 254 characters prior to connecting in Tableau, or upgrade the Excel data source.