How to add a custom color palette to Tableau

Tableau color palette is applied to the data visualization you see in the Worksheet.

You can add new colors to Tableau color palette by modifying the Preferences.tps file that comes with Tableau Desktop.

The file is usually generated on ~/Documents/My Tableau Repository path.

When you open the Preferences.tps file, you will its XML content as follows:

<?xml version='1.0'?>


To add a new color palette, you need to add the <preferences> tag under the <workbook> tag first.

<?xml version='1.0'?>


Inside the <preferences> tag, add a <color-palette> tag and define the name and type attributes of your color palette.

For example, I will add the following color palette from website:

Here’s how to add the color palette to Tableau:

<?xml version='1.0'?>

        <color-palette name="Nathan palette" type="regular" >

The type attribute in <color-palette> determines where the palette can be used:

  • regular is used for categorical data
  • ordered-sequential is used for continuous data
  • ordered-diverging is used for a diverging range of data

Once the palette is defined, save the changes to Preferences.tbs file and restart your Tableau application.

To apply the color palette, select the Color mark from the Marks shelf and click on Edit Colors... button:

Inside the Edit Colors window, click on Select Color Palette dropdown.

You will see your custom color palette at the bottom of the dropdown options.

Click on the palette, then click on the Assign Palette button.

Click OK and you’ll see the colors applied to the visualization you have in your sheet.

Here are the steps to follow to change the color palette:

And that’s how you apply a custom color palette in Tableau.

For more information, visit Tableau’s Create Custom Color Palettes documentation page.

Level up your programming skills

I'm sending out an occasional email with the latest programming tutorials. Drop your email in the box below and I'll send new stuff straight into your inbox!

No spam. Unsubscribe anytime.