ColorData["scheme"]
gives a function that generates colors in the named color scheme when applied to parameter values.
ColorData["scheme","property"]
gives the specified property of a color scheme.
ColorData["collection"]
gives a list of color schemes in a named collection.
gives a list of named collections of color schemes.
ColorData
ColorData["scheme"]
gives a function that generates colors in the named color scheme when applied to parameter values.
ColorData["scheme","property"]
gives the specified property of a color scheme.
ColorData["collection"]
gives a list of color schemes in a named collection.
gives a list of named collections of color schemes.
Details
- ColorData["scheme"][par] or ColorData["scheme",par] gives the RGBColor object corresponding to parameter value par in the specified scheme.
- Typical collections of schemes include:
-
"Gradients" continuous normalized color gradients "Indexed" colors indexed by successive integers "Named" collections of named colors "Physical" colors determined by physical parameters - By default, color gradients have a single parameter that ranges from 0 to 1.
- ColorData[{"gradient","Reverse"}] gives a color gradient that ranges from 0 to 1 with the order of colors reversed.
- ColorData[{"gradient",{min,max}}] gives a color gradient that ranges from min to max.
- ColorData[n,…] uses the n
indexed color palette. - Possible properties in ColorData["scheme","property"] include:
-
"ColorFunction" a color function to be applied to parameters "ColorList" list of colors for finite indexed color schemes "ColorRules" color rules for discrete color schemes "Image" a graphics image showing colors in the scheme "Name" English name for the color scheme "Panel" a clickable panel showing colors in the scheme "ParameterCount" the number of parameters used in the scheme "Range" range of possible values for the first parameter {"Range",i} range of possible values for the 
parameter - Ranges are specified as they would be for a slider:
-
{xmin,xmax} continuous values from xmin to xmax {xmin,xmax,dx} discrete values in steps dx {{x1,x2,…}} specific discrete values - ColorData["DefaultPlotColors"] gives the default sequence of colors used by functions such as Plot and ListPlot.
- ColorData["DefaultChartColors"] gives the default sequence of colors used by functions such as PieChart and BarChart.
- ColorData["scheme"] gives a ColorDataFunction object.
Examples
open all close allBasic Examples (5)
Return a function that generates colors:
ColorData["TemperatureMap"]Plot a surface with gradient colors:
Plot3D[Exp[-x ^ 2 - y ^ 2], {x, -2, 2}, {y, -2, 2}, ColorFunction -> (ColorData["TemperatureMap"][#3]&)]Reverse the order of gradient colors:
Plot3D[Exp[-x ^ 2 - y ^ 2], {x, -2, 2}, {y, -2, 2}, ColorFunction -> (ColorData[{"TemperatureMap", "Reverse"}][#3]&)]Use an indexed color scheme for plot styles:
Plot[Evaluate[Table[Sin[x + Pi n / 4], {n, 0, 7}]], {x, 0, 2Pi}, Filling -> Axis, PlotStyle -> ColorData[3, "ColorList"]]Use an indexed color scheme for contour shading:
ContourPlot[x + Sin[x ^ 2 + y ^ 2], {x, -4, 4}, {y, -4, 4}, Contours -> 9, ContourShading -> ColorData[35, "ColorList"]]Scope (23)
Schemes and Collections (6)
Obtain the list of collections:
ColorData[]Find the schemes that belong to each collection:
Short[ColorData["Gradients"]]Short[ColorData["Indexed"]]ColorData["Named"]ColorData["Physical"]Gradients are continuous color functions that are suitable for ColorFunction:
DensityPlot[y + Sin[x ^ 2 + 3y], {x, -3, 3}, {y, -3, 3}, ColorFunction -> ColorData["SunsetColors"]]ColorData[{"gradient","Reverse"}] returns a gradient color function with the reversed color order:
DensityPlot[y + Sin[x ^ 2 + 3y], {x, -3, 3}, {y, -3, 3}, ColorFunction -> ColorData[{"SunsetColors", "Reverse"}]]Indexed schemes consist of lists of colors associated with discrete values:
Short[ColorData[3, "ColorList"], 4]data = Table[RandomReal[{2i, 2 i + 1}, {20}], {i, 7}];ListLinePlot[data, PlotStyle -> ColorData[3, "ColorList"], InterpolationOrder -> 2]Named schemes are sets of well-known named colors:
Graphics[{ColorData["HTML", "Violet"], Disk[], ColorData["HTML", "MidnightBlue"], Disk[{1, 0}]}]Physical schemes return colors based on physical values:
DensityPlot[x, {x, 380, 750}, {y, 0, 50}, ColorFunction -> ColorData["VisibleSpectrum"], ColorFunctionScaling -> False, AspectRatio -> Automatic, PlotRangePadding -> 10, FrameTicks -> {{None, None}, {Automatic, None}}]Properties (10)
Find all the properties of color schemes:
ColorData["Properties"]"ColorFunction" returns the ColorDataFunction object:
ColorData["SouthwestColors", "ColorFunction"]Get the list of colors in a discrete color scheme:
ColorData[38, "ColorList"]Short[ColorData["Atoms", "ColorList"]]Gradients and physical schemes cannot return color lists:
ColorData["PlumColors", "ColorList"]Get the color replacement rules from a discrete color scheme:
ColorData[42, "ColorRules"]Short[ColorData["Legacy", "ColorRules"], 3]Get a representative image of a scheme:
ColorData["DarkRainbow", "Image"]ColorData[22, "Image"]ColorData["HTML", "Image"]ColorData["VisibleSpectrum", "Image"]ColorData["HTML", "Name"]Get a clickable panel of a scheme:
ColorData["SunsetColors", "Panel"]ColorData[17, "Panel"]ColorData["GeologicAges", "Panel"]ColorData["BlackBodySpectrum", "Panel"]Get a number of parameters required in a scheme:
ColorData["AuroraColors", "ParameterCount"]Get a range of possible values for the first parameter:
ColorData["GrayYellowTones", "Range"]ColorData[12, "Range"]Short[ColorData["HTML", "Range"]]ColorData["VisibleSpectrum", "Range"]The range value can be directly used in controls, such as Slider:
{Slider[Dynamic[w], ColorData["GrayYellowTones", "Range"]], Dynamic[w]}{Slider[Dynamic[x], ColorData[12, "Range"]], Dynamic[x]}{Slider[Dynamic[y], ColorData["HTML", "Range"]], Dynamic[y]}{Slider[Dynamic[z], ColorData["VisibleSpectrum", "Range"]], Dynamic[z]}Property Values (7)
Property values can be any valid Wolfram Language expression:
ColorData["HypsometricTints", "Image"]Take[ColorData[37, "ColorRules"], 3]ColorData["SouthwestColors", 0.5]Each scheme returns a ColorDataFunction object:
ColorData["GrayYellowTones"]ColorData[12]ColorData["HTML"]ColorData["VisibleSpectrum"]ColorDataFunction returns RGB colors when applied to values within a specific range:
ColorData["GrayYellowTones"][.5]
%//InputFormColorData[12][7]
%//InputFormColorData["HTML"]["WhiteSmoke"]
%//InputFormColorData["VisibleSpectrum"][550]
%//InputFormGradients and physical schemes are defined on continuous intervals:
ColorData["GrayYellowTones", "Range"]ColorData["VisibleSpectrum", "Range"]Indexed schemes are defined on discrete values:
ColorData[12, "Range"]An indexed range can turn into a list by applying Range:
Apply[Range, %]Named schemes are defined on specific sets of values:
Short[ColorData["HTML", "Range"]]A property that is not applicable returns Missing["NotApplicable"]:
ColorData["SouthwestColors", "ColorList"]ColorData["SouthwestColors", "ColorRules"]Generalizations & Extensions (2)
Some schemes have specialized images and panels:
ColorData["Atoms", "Image"]ColorData["Atoms", "Panel"]Some indexed schemes are defined on whole numbers:
ColorData[1, "Range"]In these cases, only parts of lists and rules are returned:
ColorData[1, "ColorList"]ColorData[1, "ColorRules"]Applications (9)
Use gradients to define color function:
dem = Import["http://exampledata.wolfram.com/hailey.dem.gz", "Data"];ReliefPlot[dem, MaxPlotPoints -> 300, ColorFunction -> ColorData["BrightBands"]]Use gradients to represent population:
Graphics[{EdgeForm[{StandardGray, Opacity[.5]}], With[{p = QuantityMagnitude[CountryData[#, "Population"]]}, {If[NumberQ[p], ColorData["SolarColors"][1. - p 10 ^ -9], White], CountryData[#, {"SchematicPolygon", "Robinson"}]}]& /@ CountryData[]}, PlotRange -> Automatic]Combine various surface properties with ColorData using Directive:
Plot3D[Evaluate[ D[(x^2 + y^2) Exp[1 - x^2 - y^2], y]], {x, -2, 2}, {y, -2, 2}, ColorFunction -> (Directive[Opacity[#3], ColorData["ThermometerColors"][#3]]&), PlotRange -> All, Mesh -> None]Use color lists of indexed schemes in ContourShading:
ContourPlot[Sin[x]Sin[y], {x, -0, 3Pi}, {y, 0, 3Pi}, ContourShading -> ColorData[8, "ColorList"], FrameTicks -> False]Use partition of a color list in MeshShading:
ParametricPlot3D[{(2 + Cos[v])Cos[u], (2 + Cos[v])Sin[u], Sin[v]}, {u, 0, 2Pi}, {v, 0, 2Pi}, Mesh -> 15, Lighting -> "Neutral", MeshShading -> Partition[ColorData[9, "ColorList"], 2]]Replace HTML color names with RGB values using color rules:
Grid[{{a, b, c}, {d, e, f}, {g, h, i}}, Frame -> All, Background -> {{"LightSteelBlue", "Salmon", "PaleGreen"}}] /. ColorData["HTML", "ColorRules"]Use color names combined with color rules in ArrayPlot:
w = Partition[First@ColorData["WebSafe", "Range"], 12];Short[w, 3]ArrayPlot[w, ColorRules -> ColorData["WebSafe", "ColorRules"]]Represent atoms with appropriate colors:
Graphics3D[{Specularity[White, 50], ColorData["Atoms", "H"], Sphere[{0, 0, 0}, .7], Sphere[{1.4, 0, 0}, .7], ColorData["Atoms", "O"], Sphere[{.7, 0, .7}]}, Lighting -> "Neutral"]Use physical schemes to represent various spectra:
Blackbody[T_] := With[{h = 6.6262 10 ^ -34, c = 2.99792458 10 ^ 8, k = 1.3807 10 ^ -23}, Plot[(2h c ^ 2 / λ ^ 5 ) / (Exp[h c / (λ k T)] - 1), {λ, 10 ^ -9, 1000 10 ^ -9}, MaxRecursion -> 0, ColorFunction -> (ColorData["VisibleSpectrum"][10 ^ 9#]&), ColorFunctionScaling -> False, Filling -> Axis, Ticks -> None, PlotLabel -> Row[{T, " K"}]]]Row[Table[Blackbody[t], {t, {2000, 4000, 6000, 8000}}], Spacer[2]]The integrated spectrum color for different temperatures:
Graphics[{EdgeForm[Gray], Table[{ColorData["BlackBodySpectrum", 1000 t], Text[1000t"K", {2t, 1.5}, {-1, 0}, {0, 1}], Disk[{2t, 0}, .9]}, {t, 10}]}]Properties & Relations (5)
Gradients can be referred to by their names only in ColorFunction:
DensityPlot[Sin[x]Sin[y], {x, -4, 4}, {y, -3, 3}, ColorFunction -> "AvocadoColors"]Gradients and physical schemes clip values outside of the ranges:
DensityPlot[x, {x, -1, 2}, {y, 0, 1}, ColorFunction -> ColorData["SunsetColors"], ColorFunctionScaling -> False]DensityPlot[x, {x, 300, 800}, {y, 0, 1}, ColorFunction -> ColorData["VisibleSpectrum"], ColorFunctionScaling -> False]Indexed schemes repeat the colors periodically:
ArrayPlot[{Range[40]}, ColorFunction -> ColorData[10], ColorFunctionScaling -> False, AspectRatio -> .3]Indexed schemes take floors of noninteger numbers:
ColorData[10][2]//InputFormColorData[10][2.5]//InputFormChemicalData uses ColorData["Atoms"] for element colors:
ChemicalData["Benzthiazuron", "MoleculePlot"]ChemicalData["Benzthiazuron", "HillFormula"]Possible Issues (3)
Named schemes return a list of names as the "Range":
r = ColorData["HTML", "Range"];Short[r, 4]Dimensions[r]First can be used to take the list of names:
n = First[ColorData["HTML", "Range"]];Short[n, 4]In a plot with multiple ColorFunction slots, the first slot is chosen, if not specified:
Plot3D[ Exp[1 - x^2 - y^2], {x, -2, 2}, {y, -2, 2}, ColorFunction -> ColorData["Rainbow"], PlotRange -> All, Mesh -> None]Specify a pure function so that the plot is colored by height values:
Plot3D[ Exp[1 - x^2 - y^2], {x, -2, 2}, {y, -2, 2}, ColorFunction -> Function[{x, y, z}, ColorData["Rainbow"][z]], PlotRange -> All, Mesh -> None]Certain gradients may produce artifacts due to undersampling:
Plot3D[ Exp[1 - x^2 - y^2], {x, -2, 2}, {y, -2, 2}, ColorFunction -> (ColorData["BrightBands"][#3]&), PlotRange -> All, Mesh -> None]Increasing PlotPoints may reduce the problem:
Plot3D[ Exp[1 - x^2 - y^2], {x, -2, 2}, {y, -2, 2}, ColorFunction -> (ColorData["BrightBands"][#3]&), PlotPoints -> 80, PlotRange -> All, Mesh -> None]Neat Examples (4)
Generate grainy texture from random noise:
ReliefPlot[Table[RandomReal[](Sin[x + y ^ 2] + Sin[x ^ 2 + 3y]), {x, -3, 3, .01}, {y, -3, 3, .01}], ColorFunction -> ColorData["SouthwestColors"]]Random bumpy pattern using rainbow colors:
ReliefPlot[Table[Evaluate[Sum[Sin[RandomReal[4, 2].{x, y}], {5}]], {x, 0, 10, .05}, {y, 0, 10, .05}], ColorFunction -> ColorData["Rainbow"]]Thumbnails of all the gradients:
Grid[Partition[Show[ColorData[#, "Image"], ImageSize -> 110]& /@ ColorData["Gradients"], 4, 4, 1, {}], Spacings -> .5]Thumbnails of all the indexed schemes:
Grid[Partition[Framed[Show[ColorData[#, "Image"], ImageSize -> 100], FrameStyle -> Gray]& /@ ColorData["Indexed"], 4, 4, 1, {}], Spacings -> .25]See Also
ColorDataFunction Blend RGBColor ColorFunction LightDarkAutoColorRules PlanckRadiationLaw
Function Repository: SampleColors TurboColor ViridisColor
Related Guides
History
Introduced in 2007 (6.0) | Updated in 2010 (8.0) ▪ 2025 (14.2) ▪ 2026 (15.0)
Text
Wolfram Research (2007), ColorData, Wolfram Language function, https://reference.wolfram.com/language/ref/ColorData.html (updated 2026).
CMS
Wolfram Language. 2007. "ColorData." Wolfram Language & System Documentation Center. Wolfram Research. Last Modified 2026. https://reference.wolfram.com/language/ref/ColorData.html.
APA
Wolfram Language. (2007). ColorData. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/ColorData.html
BibTeX
@misc{reference.wolfram_2026_colordata, author="Wolfram Research", title="{ColorData}", year="2026", howpublished="\url{https://reference.wolfram.com/language/ref/ColorData.html}", note=[Accessed: 12-June-2026]}
BibLaTeX
@online{reference.wolfram_2026_colordata, organization={Wolfram Research}, title={ColorData}, year={2026}, url={https://reference.wolfram.com/language/ref/ColorData.html}, note=[Accessed: 12-June-2026]}