How to Customize Colors in Tableau

How to Customize Colors in Tableau

Now you’ve got some fonts that aren’t basic, how about some custom colors? I really like matching my visualizations to my report, which is almost always based on the color scheme of the organization I’m working with. Let me tell you though, this can be a bit of a beast, so let’s get started.

First, identify the colors you want to use. I suggest Adobe Color, which will allow you to upload a photo and get HEX codes (along with complementary colors and other fun things). Of course, you might be lucky and already have your HEX codes available.

Next, you’ll need to determine whether you want to add a categorical, sequential, or diverging palette. I’ll show you categorical. You can add the others as needed using the same method.

With your HEX codes in hand, locate your Tableau Repository. Depending on where you installed this, it could take a minute. When you locate it, there will be a Preferences.tps you need to open in a text editing program.

Deven Wisner Tableau Colors 1Deven Wisner Tableau Colors w

Now, get started with code. You want to add the following before copying anything into the text edit.

Deven Wisner Tableau Colors 3

You will need to copy the basic code down and insert your HEX codes. Tableau lists all the sets of you would possibly need here. Copy, paste, and customize.

HERE IS THE TRICKY PART…

Make sure you are using straight quotes. Anything else will cause all sorts of errors. I’ve included examples of a correct and incorrect repository. This is often not a matter of inserting quotes but changing the auto-correction in the program.

Deven Wisner Tableau Colors 4Deven Wisner Tableau Colors 5.png

Save and close your text editor and open Tableau! To test your colors, open up a sample dataset. On a worksheet, drag a dimension onto the Color Mark. You’ll immediately see those basic default colors but don’t worry – we’re fixing that!

Deven Wisner Tableau Colors 6

Select the Color Mark and click Edit Colors. You should see yours at the bottom!

Deven Wisner Tableau Colors 7

Select your color and be sure to click Assign, otherwise nothing will change. Close the editor and check out your new colors!

Deven Wisner Tableau Colors 8

SUCCESS!

Deven Wisner Tableau Colors 9

If you followed along, you just completed some serious steps in customizing your Tableau visualizations. I call it a small but mighty change. You can go forth knowing that your visualizations are more customized and specific to your project!

P.S. This is cross-posted on Ann K. Emery’s blog (because awesome people stick together)!

« Back to Blog