Skip to content

Color Matching

Find FFXIV dyes that best match any hex color you provide, using perceptual color distance algorithms.

Distance Methods

MethodDescription
rgbEuclidean distance in RGB space — fast, not perceptually uniform
cie76CIE76 ΔE in Lab space — older standard, reasonable accuracy
ciede2000CIEDE2000 ΔE — current ISO standard for perceptual color difference
oklabOklab ΔE — modern algorithm, excellent perceptual uniformity (default)
hyabHyAB — hybrid approach, good for large color differences
oklch-weightedOKLCh with custom kL/kC/kH weights for lightness/chroma/hue emphasis

Default: oklab is the best general-purpose choice. Use oklch-weighted when you want to prioritize hue matching over lightness (e.g. kL=0.5, kH=2).


GET /v1/match/closest

Find the single closest FFXIV dye to a given hex color.

Parameters

NameInRequiredDescription
hexqueryYesHex color (#RRGGBB or RRGGBB)
methodqueryNoDistance algorithm (default: oklab)
excludeIdsqueryNoComma-separated IDs to exclude from results
localequeryNoLocale for localizedName
kLqueryNoLightness weight for oklch-weighted (default: 1.0)
kCqueryNoChroma weight for oklch-weighted (default: 1.0)
kHqueryNoHue weight for oklch-weighted (default: 1.0)
GET/v1/match/closest?hex=FF6B6B&method=oklab&locale=en
hexqueryrequired
Hex color — #RRGGBB or RRGGBB
methodquery
Distance algorithm
localequery
en, ja, de, fr, ko, zh

Example response:

json
{
  "success": true,
  "data": {
    "dye": {
      "itemID": 48227,
      "stainID": 52,
      "name": "Carmine Red",
      "hex": "#e50b18",
      "rgb": { "r": 229, "g": 11, "b": 24 },
      "category": "Red",
      ...
    },
    "distance": 0.0521,
    "method": "oklab",
    "inputHex": "#FF6B6B"
  },
  "meta": { ... }
}

Distance values are unitless floats. For oklab, values below 0.05 are perceptually very close, and above 0.2 are noticeable differences.


GET /v1/match/within-distance

Find all dyes within a color distance threshold. Results are sorted closest-first.

Parameters

NameInRequiredDescription
hexqueryYesHex color (#RRGGBB or RRGGBB)
maxDistancequeryYesMaximum distance threshold (min 0.01)
methodqueryNoDistance algorithm (default: oklab)
limitqueryNoMax results (1–136, default 20)
excludeIdsqueryNoComma-separated IDs to exclude
localequeryNoLocale for localizedName
kLqueryNoLightness weight for oklch-weighted
kCqueryNoChroma weight for oklch-weighted
kHqueryNoHue weight for oklch-weighted
GET/v1/match/within-distance?hex=FF6B6B&maxDistance=0.15&method=oklab&limit=10&locale=en
hexqueryrequired
Hex color — #RRGGBB or RRGGBB
maxDistancequeryrequired
Maximum Oklab distance (try 0.05–0.30)
methodquery
Distance algorithm
limitquery
Max results (1–136)
localequery
en, ja, de, fr, ko, zh

Example response:

json
{
  "success": true,
  "data": {
    "results": [
      { "dye": { "itemID": 48227, "name": "Carmine Red", "hex": "#e50b18", ... }, "distance": 0.0341 },
      { "dye": { "itemID": 48247, "name": "Rust Red", "hex": "#d4320e", ... }, "distance": 0.0892 }
    ],
    "inputHex": "#FF6B6B",
    "maxDistance": 0.15,
    "method": "oklab",
    "resultCount": 2
  },
  "meta": { ... }
}

If no dyes fall within maxDistance, results will be an empty array and resultCount will be 0. Try increasing maxDistance — for oklab, a value of 0.3 covers most of the visible color space.

Not affiliated with Square Enix.