Loading

How to Replace Data Sources in Tableau Workbooks

Дата публикации: Jan 7, 2026
Предварительные требования
Before switching data sources, ensure that the field names, data types, and data roles of the fields (e.g., Discrete Dimension, Continuous Measure) in the new data source match those in the old data source. If they do not match, calculated fields or views may break.
Задача

You may need to switch the data source a workbook refers to, such as when moving from a development phase to a production phase or changing the connection database. Use one of the following methods to replace the data source depending on your situation.

Действия

Select the option that best fits your requirements. As a best practice, always save a backup copy of your workbook and data sources before replacing connections. 

Option 1: Replace Data Source (Tableau Desktop)

This is the standard method available in Tableau Desktop and can be used for all types of data sources. However, this method cannot be used if you wish to replace a published data source with a published data source from a different site. For details, see Replace Data Sources

  1. Open the workbook in Tableau Desktop and connect to the new data source.
  2. Select Data or right-click (control-click on a Mac) the data source in the Data pane.
  3. Select Replace Data Source.
  4. Select the Current and Replacement data sources, then click OK.

Note: Some settings in the workbook, such as default properties, may be reset using this method. For details, see What Gets Reset or Lost After Replacing a Data Source in Tableau Desktop.

Option 2: Replace Published Data Source (Tableau Desktop or Web Authoring)

This operation is only available between data sources published to the same Tableau Server or Tableau Cloud site.

  1. Navigate to the Data Source tab in the editing screen (Tableau Desktop or Web Authoring).
  2. Click the drop-down arrow (▼) next to the data source name and select Replace.
  3. Select the new published data source from the list, then click Connect.

Option 3: Edit Server and Site Path (Tableau Desktop)

This operation is only available between published data sources but supports replacing data sources across different sites (e.g., moving from a test site to a production site).

  1. In Tableau Desktop, select Data > the data source from the Saved Data Sources list, or right-click (control-click on a Mac) the data source in the Data pane.
  2. Select Tableau Data Server > Edit Server and Site Path.
  3. Specify the Tableau Server URL, site, data source or connection name, then click OK.

For details on moving workbooks and data sources between sites, see Move Workbooks and Projects Between Sites.

Option 4: Overwrite Published Data Source (Tableau Desktop and Web Authoring)

By publishing a new data source with the same name as an existing published data source, you can replace the content while maintaining the connection. This allows for bulk replacement of connections for many workbooks, but requires careful verification due to the wide impact.

  1. Create a new data source in Tableau Desktop or Web Authoring following the steps in Connect to Your Data.
  2. Publish (overwrite) the data source to the same project with the same name as the existing one.
    • Tableau Desktop: After creating the new data source, select Data > Publish to Server. For details, see Publish a Data Source.
    • Web Authoring: In the Web editing screen, use File > Publish As to publish with the same name and overwrite the existing one.

Note: If you want to keep the original data source, it is recommended to make a copy beforehand following the steps in Edit and test changes. To revert changes, see Restore a data source revision

 

If issues occur after replacing the data source, refer to the following Knowledge Articles:

Дополнительные ресурсы
Номер статьи базы знаний

005232823

 
Загрузка
Salesforce Help | Article