Direct answer
Use a sequential palette (one hue, increasing intensity) for a single quantity that runs low-to-high, a diverging palette (two hues meeting at a neutral midpoint) when there's a meaningful zero or target to diverge from, and a categorical palette (distinct, non-ordered hues) for unordered groups; keep any multi-series legend to the smallest set of colors a viewer can hold in memory.
Structured elaboration
- Sequential: for a quantity like "revenue per region" where only magnitude matters, one hue from light to dark (or low to high saturation) preserves the sense of order.
- Diverging: for a quantity like "percent change vs. last quarter" or "actual minus target," use two contrasting hues (e.g. blue-to-red) meeting at white/gray at zero, so the viewer instantly sees direction as well as magnitude.
- Categorical: for genuinely unordered groups (product lines, regions, channels), pick 4-6 maximally distinguishable hues; going past 8-10 categorical colors makes the legend unreadable regardless of how distinct the hues are.
- Continuous vs. discrete color scales: a continuous scale blends smoothly across the full range of values (e.g. a choropleth, a map where each region is shaded according to its value, shaded on a smooth gradient), which best conveys fine-grained magnitude differences; a discrete/binned scale groups values into a small number of steps (e.g. 5 quantile buckets), which trades precision for a legend a viewer can actually name and remember, and is usually the better choice once the audience needs to talk about "the top bucket" rather than an exact value.
- Multi-series legend design: order series in the legend to match their visual order in the chart (e.g. top-to-bottom matching the lines' end positions), use consistent colors for the same entity across every chart in a dashboard, and give each series a clear, descriptive name rather than a generic label like "Series 3", vary line style (solid/dashed/dotted) alongside color so series stay distinguishable in grayscale or for colorblind viewers, and make the legend interactive (click to isolate/hide a series) when there are more than 4-5 series.
Worked example
A dashboard showing "gross margin by product line" for three product lines, Alpha at 22% margin, Beta at 18% margin, and Gamma at 9% margin (unordered categories), should use a 3-color categorical palette (blue for Alpha, orange for Beta, green for Gamma) so each line reads as a distinct entity rather than an ordered scale; a companion tile showing "margin vs. target" for the same three lines, Alpha +4pts, Beta +1pt, Gamma -3pts, should instead use a diverging red-white-green palette centered at 0, so Gamma's bar renders in red, Beta's in near-white, and Alpha's in green, letting a viewer read direction (over or under target) at a glance without reading the numbers.
Trade-offs and pitfalls
The most common error is using a rainbow (unordered, high-saturation) palette for genuinely ordered/quantitative data, which implies false category boundaries where there are none; a second common error is reusing the same hue for a different entity across two different charts on the same dashboard, which silently breaks the color-to-entity mapping a viewer has learned.