Install From the Command Line

This article describes how to use the command line to install Tableau Desktop, Tableau Prep Builder and Tableau Desktop Public Edition and perform other installation actions, such as activation and registration, as well as how to uninstall the product.

For more detailed information about finding the installer and your product key, see Where's the installer? and Find Your Product Key.

Note: If you are upgrading, see Upgrade Tableau Desktop and Tableau Prep Builder for information about preparing for an upgrade.

Tableau enables certain features for you by default such as usage reporting or automated product updates (Tableau Desktop only). For information about how to turn off these features and more, see Change Installation Settings after Installation(Link opens in a new window).

Before you begin

  • Compatibility with Server: Tableau products are not always released at the same time. When installing a new version of Tableau Desktop, make sure it is compatible with Tableau Server. See Finding and Resolving Compatibility Issues.
  • Install Desktop and Prep on the same computer: Tableau Prep Builder is designed to work with Tableau Desktop. It is recommended that you install Tableau Prep Builder on the same computer as Tableau Desktop.
  • Do not install Tableau Prep Builder on the same computer running Tableau Server: Tableau Server Resource Manager (SRM) can't distinguish between Tableau Server protocol server process and Tableau Prep Builder protocol server process. If the computer resources are exhausted, SRM may terminate the protocol server process belonging to Tableau Prep Builder, which has no recovery mechanism.
  • Windows installer requirement: If you're using a deployment tool that requires the Windows installer (.msi file) to install Tableau Desktop or Tableau Prep Builder, follow the instructions in Extract and run the Windows (MSI) installer to extract the .msi file from the Tableau installer .exe file.

Click on the tab below for the product you are installing to view the installation steps.

Windows

  1. Run the installer .exe file from the computer's command line as an administrator.
    If you need to extract the .msi files, follow the instructions in the Extract and run the Windows (MSI) installer section of this article.

    The syntax for running the Tableau installer from the command line is:

    tableau_<product_installer_name>.exe /option1 /option2 PROPERTY1 PROPERTY2

    • tableau_<product_installer_name>.exe: This is the Tableau installer for the product and version you're installing.

    • Options: The options that you use specify how the installation process should run. For example, whether it should display output while installing or whether it should create log files. See Installer options for the list of available options.

    • Properties: These settings specify configuration settings that the installer should make during the installation process. See Installer properties for the list of available properties.
  2. Run the command from the directory where the .exe file is located or specify a full path to the location of the .exe file on the computer. Do not run the setup program from a shared directory on your network. Instead, download the .exe file to a directory on the computer where you're installing.

    Example

    The following example shows an installer command with some options and some property settings.

    tableauDesktop-64bit-2021-4-4.exe /quiet /norestart ACCEPTEULA=1 AUTOUPDATESERVER="assets.intranet.lan" REPORTINGSERVER="http://mytableau"

    The command in the example does the following:

    • Installs the 64-bit version of Tableau Desktop 2021.4.4.

    • Runs the installer in quiet mode, meaning that the setup process doesn't display prompts, UI or the licence dialog box.

    • Sets the installation to finish without restarting.

    • Accepts the End User Licence Agreement (EULA).

    • Configures a non-default product update server.

    • Configures the product to send licence reporting to an internal Tableau Server.

Mac

Important: Only install Tableau on the root drive so that FlexNet and device drivers install to the correct location.

  1. Upload a copy of the Tableau Desktop DMG file to a network share and tell users to download it to their Mac computers from there. You can follow the prompts to complete the installation.

    You can also create a .sh script that mounts the DMG file and copies Tableau to your user's computers. The following examples shows a script that performs this task for different versions of Tableau Desktop.

    Example: Tableau Desktop version 10.2 and later versions

    #!/usr/bin/env bash
    # mount the DMG and copy Tableau.app to a folder
    output=`yes | hdiutil attach "<DMG_name>.dmg"`
    sleep 10
    volName=`echo "$output" | tail -n 1 |sed 's;^.*\(/Volumes.*$\);\1;'`
    open "/Volumes/Tableau/Tableau Desktop.pkg"
    # dismount the Tableau DMG volume
    hdiutil detach """${volName}""" -force
  2. (optional) Run the installer application to perform a silent installation. Type the following at a Terminal prompt:

    sudo installer -pkg <path and name of .pkg file> -target /

    This will prompt for an admin password, and then perform a mostly silent install. You will see these three lines:

    • installer: Package name is Tableau Desktop

    • installer: Upgrading at base path /
    • installer: The upgrade was successful.

Select the drivers to install automatically

By default, several data source drivers are automatically installed with Tableau Desktop. For a complete list, see Before You Install.

Note: Starting with version 2019.4, only the PostgreSQL driver is automatically installed on the Mac.

To prevent one or all of the drivers from installing automatically, first run the Mac installer application against the Desktop.pkg with ‑showChoiceChangesXML to generate a plist file containing all possible customisations. The syntax is:

installer -showChoiceChangesXML -pkg <path and name of .pkg file> –target / > <name of plist>

Example:

installer -showChoiceChangesXML -pkg Install\ Tableau\ Desktop.pkg –target / > InstallTableauDesktopChoices.xml

For the Oracle driver, the section in the resulting plist file looks like the following:

<dict> <key>attributeSetting</key> <integer>1</integer> <key>choiceAttribute</key> <string>selected</string> <key>choiceIdentifier</key> <string>com.tableau.oracle</string> </dict>

To prevent a driver from being installed, do the following:

  1. In the .plist file, change the value of <integer> from 1 to 0 for any drivers you don't want to install automatically.

  2. Save the file, then pass it to the installer by adding it to the command line using the following command:

    -applyChoiceChangesXML <pathToXMLFile>

The full command line might look something like this after you’ve created a plist file with the changes you want in it:

sudo installer -pkg Install\ Tableau\ Desktop.pkg -applyChoiceChangesXML InstallTableauDesktopChoices.xml -pkg -target /

For documentation on the Mac Installer application, see Apple Developer(Link opens in a new window) documentation.

Disable the desktop shortcut

To prevent the Tableau installer from creating a desktop shortcut for Tableau Desktop, generate the XML file as per the previous section and change the integer value from 0 to 1 in the following section.

<dict> <key>attributeSetting</key> <integer>0</integer> <key>choiceAttribute</key> <string>selected</string> <key>choiceIdentifier</key> <string>com.tableau.desktopShortcut</string> </dict>

Note: This option is only available for Windows.

  1. Run the installer .exe file from the computer's command line as an administrator.

    The syntax for running the Tableau installer from the command line is:

    tableau_<product_installer_name>.exe /option1 /option2 PROPERTY1 PROPERTY2

    • tableau_<product_installer_name>.exe: This is the Tableau installer for the product and version you're installing.

    • Options: The options that you use specify how the installation process should run. For example, whether it should display output while installing or whether it should create log files. See Installer options for the list of available options.

    • Properties: These settings specify configuration settings that the installer should make during the installation process. See Installer properties for the list of available properties.
  2. Run the command from the directory where the .exe file is located or specify a full path to the location of the .exe file on the computer. Do not run the setup program from a shared directory on your network. Instead, download the .exe file to a directory on the computer where you're installing.

    Example

    The following example shows an installer command with some options and some property settings.

    tableauPrepBuilder-64bit-2021-4-4.exe /quiet /norestart ACCEPTEULA=1 CRASHDUMP="0" SENDTELEMETRY="0"

    The command in the example does the following:

    • Installs Tableau Prep Builder 2021.4.4.

    • Runs the installer in quiet mode, meaning that the setup process doesn't display prompts, UI or the licence dialog box.

    • Sets the installation to finish without restarting.

    • Accepts the End User Licence Agreement (EULA).

    • Sets error reporting to off.

    • Sets usage reporting to off

Extract and run the Windows (MSI) installer

If you're using a deployment tool that requires the Windows installer (.msi file) to install Tableau Desktop or Tableau Prep Builder, you can extract the .msi file from the Tableau installer .exe file. When you extract the .msi file, you see the installer .msi file plus .msi files for each database driver that is included in the Tableau Desktop install process.

To extract the .msi file, you can use a third-party tool like WiX Toolset.

Disclaimer: This solution includes information about a third-party product. While we make every effort to keep references to third-party content accurate, WiX Toolset options might change without notice. For the most up to date information, please consult WiX documentation. For assistance with the WiX utilities, contact the WiX users mailing list.

  1. On the computer where you downloaded the Tableau installer, download and install the latest version of the WiX Toolset from the WiX website (http://wixtoolset.org/(Link opens in a new window)).

  2. Open a command window as an administrator and navigate to the root of the folder where you installed WiX Toolset.

  3. Run the following command:

    Dark.exe <path_to_the_Tableau_exe_installer> -x <output_folder>

    For example, run the following command:

    Dark.exe C:\tableau-setup-std-tableau-2021-1.21.0125.1838-x64.exe -x c:\output

The output folder will contain a folder named AttachedContainer that includes the .msi files.

Activate Tableau Desktop and Tableau Prep Builder

After Tableau Desktop or Tableau Prep Builder has been installed, you can activate using login-based licence management by signing into Tableau Cloud or Tableau Server. Otherwise, you need to provide a product key in order to activate the product by sending an activation request to Tableau. You can enter a product key from the command line during install (Windows) or after install (Windows and Mac).

To automate this process during install, add a single command line that includes the installer option ACTIVATE_KEY "<key>" and enter the product key in quotes. The installer applies the product key as part of the installation process.

To automate this process after install, run Tableau.exe or Tableau Prep Builder.exe after installation with the -activate <key> option, for example tableau.exe -activate <my_product_key> .

Note: If you want to activate Tableau Server using automated scripts, see Automate Licensing Tasks(Link opens in a new window) in the Tableau Server Help.

Windows

Run tableau.exe or Tableau Prep Builder.exe with the -activate option and a product key.

For example:

Tableau Desktop: "C:\Program Files\Tableau\Tableau <version>\bin\tableau.exe" -activate <product_key>

Tableau Prep Builder: “C:\Program Files\Tableau\Tableau Prep Builder <version>\Tableau Prep Builder.exe" -activate <product_key>

Mac

Run the Tableau or the Tableau Prep Builder executable with the -activate option and a product key in the /Applications path.

For example:

Tableau Desktop: "Tableau Desktop <version>.app/Contents/MacOS/Tableau" –activate <product_key>

Tableau Prep Builder: "Tableau Prep Builder <vesion>.app/Contents/MacOS./Tableau Prep Builder" –activate <product_key>

For information about exit codes that you can capture and evaluate if licensing fails, see Troubleshoot activation errors using activation exit codes in the Troubleshoot Installation article in this guide.

Register Tableau Desktop and Tableau Prep Builder

You can ensure consistent registration across your organisation by automating the task of registering individual copies of Tableau. To automate this process for Windows, add a single command line that includes the installer option REGISTER="1". The installer runs -register and registers the product.

To register Tableau from the command line, you need to prefill the registry (Windows) or .plist (Mac) values on each computer that will run Tableau Desktop and Tableau Prep Builder. For Windows, you can trigger this process during installation. For Windows and the Mac, you can perform the installation process and then use the register command line option. When Tableau starts, it reads the registration information and registers Tableau for that user.

Registration information is stored on the computer where Tableau is installed.

  • Windows: The information is in the registry.

  • Mac: The information is in the property list (.plist) file.

The registration information includes location fields that may be the same for many users (for example, city, country, and zip), and fields that are typically unique to each user (email, first_name, last_name, title).

For Tableau Desktop, you must include the "opt_in" and "privac_consent" fields to successfully register the product using the command line option.

The registration information is saved under one of the following locations:

  • Windows. Registry: HKEY_CURRENT_USER\Software\Tableau\Registration\Data

  • Mac. .plist file location: /Users/<user_name>/Library/Preferences/<.plist_file_name>

The easiest way to prefill the registry or property list values on multiple computers is to manually install and register Tableau on one computer, and then use the registry entries or property list file that are populated by that process as a template for updating the registry on other computers.

Windows

Register Tableau and create a template

  1. As an administrator on the computer, make a backup of the registry file before you make any changes to it.

  2. Install and manually register the product on at least one Windows computer. You can use the registration information as a template when installing Tableau on other computers.

    The registration information is saved in the Windows registry under the following key:

    HKEY_CURRENT_USER\Software\Tableau\Registration\Data

  3. Export the data (key) to a registry text file.

  4. Create a script that does the following:

    1. Makes a copy of the template registry text file and updates the fields that are unique for a user.

    2. Copies the updated registry text file to the user's computer.

    3. Updates the registry on that computer.

    The fields you update will depend on the information you want sent with the registration. For information on how to automate updates to the registry, see the Microsoft documentation.

    The following shows an example of the registry values that you might see in the exported registry file:

    [HKEY_CURRENT_USER\Software\Tableau\Registration\Data]
    "campaign_id"=""
    "company"=""
    "country"=""
    "db_title"=""
    "department"=""
    "elqCustomerGUID"=""
    "elqFormName"=""
    "email"=""
    "first_name"=""
    "form_environment"=""
    "form_variant"=""
    "ga_client_id"=""
    "job_role"=""
    "last_name"=""
    "lead_source"=""
    "lead_source_detail"=""
    "phone"=""
    "product_key"=""
    "product_name"=""
    "state"=""
    "title"=""
    "zip"=""
    "registration_date"=""
    "city"=""
    "industry"=""
    "opt_in"=""
    "privac_consent"=""

Use the template to register Tableau on another computer

  1. On another computer, install Tableau Desktop or Tableau Prep Builder.

  2. Run tableau.exe or Tableau Prep Builder.exe with the -register option.

    For example:

    Tableau Desktop: "Program Files\Tableau\Tableau <version>\bin\tableau.exe -register"

    Tableau Prep Builder: "Program Files\Tableau\Tableau Prep Builder<version>\Tableau Prep Builder.exe -register"

    If registration is successful, the install log file will have an entry:

    Current registration state: complete / not needed

    If registration is not successful, Tableau will close with the error code error 117. You can also check the log file, which has information about invalid or missing fields. The log file is in this location:

    Documents >My Tableau Repository or My Tableau Prep Builder Repository > Logs> log.txt

    If registration fails, the automated script you created needs to be updated. For troubleshooting tips, see Troubleshoot Your Tableau Desktop or Tableau Prep Builder Installation.

Mac

Register Tableau and create a template

To register Tableau Desktop or Tableau Prep Builder on the Mac, you can use Xcode or the defaults command to update the following property list file: com.tableau.Registration.plist.

You can find more information about how to edit OS X property list files at Apple Support.

  1. Install and manually register the product on at least one Mac computer. This creates the .plist file that you can use as a template to register Tableau Desktop or Tableau Prep Builder on other computers.

  2. Go to /Users/<user_name>/Library/Preferences and make a backup of the com.tableau.Registration.plist file that you want to use as the template.

  3. Copy the template com.tableau.Registration.plist file to the /Users/<user_name</Library/Preferences folder on the Mac where you want to install Tableau Desktop.

  4. Run the following command:

    cd /Users/<user_name>/Library/Preferences

    For example:

    cd /Users/agarcia/Library/Preferences

  5. For each .plist key you want to update, run the following command:

    defaults write com.tableau.Registration.plist <key_value>

    For example:

    defaults write com.tableau.Registration.plist Data.first_name Ashley

    defaults write com.tableau.Registration.plist Data.last_name Garcia

Use the template to register Tableau on another computer

  • On another computer, install Tableau Desktop or Tableau Prep Builder.

    During installation, you are prompted for a product key followed by the activation wizard. If you exit the program before completing activation or registration or are installing silently, start the Terminal application and then run the following commands:

    • To activate Tableau Desktop or Tableau Prep Builder run the following command:

      Tableau Desktop: "Tableau Desktop <version>.app/Contents/MacOS/Tableau" –activate <product_key>

      Tableau Prep Builder: "Tableau Prep Builder <vesion>.app/Contents/MacOS./Tableau Prep Builder" –activate <product_key>

    • To register Tableau Desktop or Tableau Prep Builder run the following command:

      Tableau Desktop: "Tableau Desktop <version>.app/Contents/MacOS./Tableau" –register

      Tableau Prep Builder: "Tableau Prep Builder <vesion>.app/Contents/MacOS./Tableau Prep Builder" –register

Uninstall Tableau Desktop and Tableau Prep Builder

While it is not necessary to uninstall previous versions of Tableau Desktop and Tableau Prep Builder when installing a newer version, you can uninstall any version of these applications if you no longer need them on your computer.

Windows

To uninstall Tableau Desktop or Tableau Prep Builder silently from the command line, do the following:

  1. Open the Command Prompt as an Administrator.

  2. In the location where the .exe was installed, run the following command:

    TableauDesktop-<product_installer_name>.exe /uninstall /quiet

    or

    TableauPrepBuilder-<product_installer_name>.exe /uninstall /quiet

    For example:

    Downloads\TableauPrepBuilder-2021-1-4.exe /uninstall /quiet

To uninstall multiple versions of Tableau Desktop from the command line do the following.

Note: This option isn't available for Tableau Prep Builder.

  1. Install the latest version of Tableau Desktop with the REMOVEINSTALLEDAPP option.

    For example: tableauDesktop-64bit-2021-4-4.exe /quiet /norestart ACCEPTEULA=1 REMOVEINSTALLEDAPP=1

  2. Confirm all older versions are uninstalled except the latest version.

  3. Uninstall the latest version. For example: tableauDesktop-64bit-2021-4-4.exe /uninstall /quiet /norestart

  4. Remove all unused folders according to the steps in Completely Removing Tableau Desktop(Link opens in a new window).

Mac

To uninstall Tableau Desktop on the Mac, do the following:

  1. If a product key deactivation or return is required, run the -return option on the Tableau object in the /Applications path. For more information, see Move or Deactivate Product Keys.
  2. Drag the application and the Desktop shortcut (if there is one) to your trash folder and then empty your trash.
  3. Uninstall any drivers that were installed automatically.
Thanks for your feedback!Your feedback has been successfully submitted. Thank you!