Skip to main content
L
Loopaloo
Buy Us a Coffee
All ToolsImage ProcessingAudio ProcessingVideo ProcessingDocument & TextPDF ToolsCSV & Data AnalysisConverters & EncodersWeb ToolsMath & ScienceGames
Guides & BlogAboutContact
Buy Us a Coffee
L
Loopaloo

Free online tools for developers, designers, and content creators. Your files are processed in your browser and are never uploaded - no accounts required. A few network utilities (like What's My IP and Currency Converter) call public APIs to do their job and say so on their pages.

support@loopaloo.com

Tool Categories

  • Image Tools
  • Audio Tools
  • Video Tools
  • Document & Text
  • PDF Tools
  • CSV & Data
  • Converters
  • Web Tools
  • Math & Science
  • Games

Company

  • About Us
  • Contact
  • Blog
  • FAQ

Legal

  • Privacy Policy
  • Terms of Service
  • Disclaimer

Support

Buy Us a Coffee

© 2026 Loopaloo. All rights reserved. Built with privacy in mind.

Privacy|Terms|Disclaimer
  1. Home
  2. Converters & Encoders
  3. Color Converter
Add to favorites

Color Converter

Convert colours between HEX, RGB, HSL, OKLCH, Lab and five more formats, check WCAG contrast, and preview colour-blind vision.

Runs locally in your browserMore converters & encodersJump to full guide
Related readingUnderstanding Color Spaces: sRGB, Display P3, and When It Matters11 minColor Accessibility: Designing for Color Blindness7 min

Initializing in your browser…

You might also like

Color Palette Generator

Generate colour palettes from one base colour, with tints and shades, contrast and colour-blindness checks, and CSS, Tailwind or JSON export.

Color Picker

Pick a colour visually, from the screen or by typing it, and copy it in ten formats with contrast, the nearest name and colour blindness previews.

Unix Timestamp Converter

Convert Unix timestamps to dates and dates to timestamps in any time zone, with seconds, milliseconds, microseconds and nanoseconds detected automatically.

An example conversion

A brand colour arrives as #E07A5F and is needed in CSS as OKLCH, checked as a text colour on white, and checked for colour-blind readers.

Colour

#E07A5F
What Color Converter produces

Formats and checks

RGB    rgb(224, 122, 95)
HSL    hsl(12.6, 67.5%, 62.5%)
OKLCH  oklch(0.68782 0.13312 35.778)
CMYK   cmyk(0%, 45.5%, 57.6%, 12.2%)
Lab    lab(62.17 37.05 32.32) under D65
Lab    lab(62.7 38.69 33.22) under D50
Nearest CSS name: salmon, 6.5 dE2000 away

On white: 2.95:1, fails AA for body and large text
Black text on it: 7.12:1, passes AAA
Deuteranopia: #A5A559, shifts 34.8 dE2000

All of these describe the same colour; only the notation changes. The Lab values differ between D65 and D50 because Lab depends on the white point, so copy the D50 figures into CSS lab() and print software. As text on a white background this orange reaches only 2.95 to 1, below the 3 to 1 needed even for large text, while black text on top of it reaches 7.12 to 1, so it works far better as a background than as a text colour. Under deuteranopia it shifts towards an olive yellow, which matters if it is used to signal something next to green.

What this converter does

Type a colour in any common notation, such as #1E90FF, rgb(), hsl(), oklch() or a CSS name like tomato, and get it in ten formats at once, each one click to copy. The same tool checks text and background colours against the WCAG contrast rules, suggests colour harmonies, and shows how the colour looks to people with colour vision deficiencies.

How it works

Colour on the web starts as three numbers for red, green and blue, but different jobs need different notations. HEX is compact and universal in CSS and design tools. RGB spells out the same numbers. HSL and HSV describe a colour by hue, saturation and lightness or brightness, which makes it easy to adjust by hand, and HSV is what most colour pickers show. OKLCH, part of CSS Color 4, is designed so that equal steps look equally different, which makes it the best choice for building tints, shades and accessible palettes. Lab and LCH are the long-standing CIE perceptual spaces used in print and colour science, and XYZ is the reference space they are built on. CMYK is shown as a simple ink estimate; real print colour depends on the paper, inks and an ICC profile, which a converter cannot know.

The input box reads almost anything you paste: 3, 4, 6 and 8 digit hex with or without the #, rgb() and rgba() with commas or spaces, hsl(), hwb(), lab(), lch(), oklab(), oklch() and all 148 CSS colour names. Below the box the tool says how it read your input and names the nearest CSS colour, with the distance in dE2000, a standard measure of how different two colours look. If you type something it cannot read, it says so and keeps showing the last valid colour. Tap the swatch to open your device's colour picker, or use From screen in browsers that support picking a colour anywhere on the screen.

Lab, LCH and XYZ depend on a white point. D65, daylight, is what sRGB and most of the web use; D50 is the print and ICC standard and is also what the CSS lab() and lch() functions use. Switch between them to get values that match the system you are copying into. The other formats are not affected.

The Contrast view puts your colour on a background of your choice, previews real text, and reports the WCAG 2 contrast ratio with pass or fail for AA and AAA at body and large text sizes: 4.5 to 1 is the usual minimum for body text, 3 to 1 for large text. The Harmony view rotates the hue to give complementary, triadic, tetradic, analogous and split-complementary sets, plus lighter and darker versions; click any swatch to copy it. The Colour vision view simulates protanopia, deuteranopia, tritanopia and achromatopsia with established models computed in linear light, and says how far each simulated colour shifts, which helps you avoid pairs that look the same to some readers.

Everything runs in your browser. The share link carries the colours and the view you are on, and your recent colours are kept in this browser only.

How to use

  1. 1Type or paste a colour in any format, tap the swatch to use a colour picker, or use From screen where it is available.
  2. 2Copy the format you need from the list; every row has its own copy button.
  3. 3Switch the white point to D50 if you are copying Lab or LCH values into CSS or a print workflow.
  4. 4Open Contrast, enter a background colour and read the WCAG pass or fail results.
  5. 5Use Harmony for matching colours or Colour vision to check how the colour appears to others.

Key features

  • HEX, RGB, HSL, HSV, OKLCH, CMYK, Lab, LCH, OKLab and XYZ at once
  • Reads hex, rgb(), hsl(), hwb(), lab(), lch(), oklab(), oklch() and 148 CSS names
  • Nearest CSS colour name with the visual difference in dE2000
  • D65 and D50 white points for Lab, LCH and XYZ
  • WCAG 2 contrast ratio with AA and AAA results and a live text preview
  • Complementary, triadic, tetradic, analogous, split-complementary and monochromatic harmonies
  • Simulation of four types of colour vision deficiency in linear light
  • Colour picker and screen eyedropper where the browser supports it
  • Recent colours remembered in this browser
  • Share links that reopen the same colours

Tips & best practices

  • Paste a colour straight from CSS, including rgba() or an 8-digit hex with transparency; the opacity is shown under the box.
  • For accessible palettes, change only the L value in OKLCH and recheck contrast.
  • Do not rely on colour alone to carry meaning; check status colours in the Colour vision view.
  • Use Swap in the Contrast view to check light text on a dark background and the reverse.

Where this fits

  • Moving a colour between tools

    Copy a brand colour from a design file as HEX and paste it into CSS as OKLCH or into a spreadsheet as RGB, without retyping numbers.

  • Checking accessibility

    Test a text colour on its background before shipping a design, and adjust until body text reaches at least 4.5 to 1.

  • Designing for colour-blind readers

    See whether a red and a green used for status messages stay distinguishable under deuteranopia, the most common form.

  • Building a small colour scheme

    Start from one colour and pick a complementary accent or analogous neighbours from the Harmony view.

Frequently asked questions

What is the difference between HSL and HSV?

Both describe hue and saturation, but HSL uses lightness, where 100 percent is always white, and HSV uses value or brightness, where 100 percent is the most vivid version of the hue. Design apps and colour pickers mostly use HSV, also called HSB.

Why use OKLCH?

OKLCH is a perceptual colour space: a change of 10 in lightness looks about the same at any hue, which is not true of HSL. That makes it reliable for generating tints and shades and for keeping contrast predictable. All current major browsers support oklch() in CSS.

Is the CMYK value ready for print?

No. It is a straightforward mathematical conversion. Real print colour depends on the press, paper and inks, described by an ICC profile, so ask your printer or use a design app with the right profile for final artwork.

What contrast ratio do I need?

WCAG 2 level AA needs at least 4.5 to 1 for body text and 3 to 1 for large text (24px, or 18.66px bold). Level AAA needs 7 to 1 and 4.5 to 1. The Contrast view shows all four results.

Why do my Lab values differ from another tool?

Usually the white point. Lab under D65 and Lab under D50 give different numbers for the same colour. CSS lab() and most print software use D50; many web tools use D65. Switch the white point to match.

What does dE2000 mean?

It is a standard measure of how different two colours look. Below about 1 the difference is invisible, around 2 to 3 it is noticeable side by side, and above 10 they look like different colours.

Related tools and how they differ

  • Color Palette Generator: Builds a whole palette from one colour; use it when you need a set of colours rather than one colour in different notations.
  • Color Picker: Lets you choose a colour visually on a canvas and sample pixels from the screen.
  • Image Color Palette Extractor: Pulls the main colours out of a photo you upload.
  • CSS Gradient Generator: Builds CSS gradients from several colour stops.

Further reading

  • Understanding Color Spaces: sRGB, Display P3, and When It Matters11 min read
  • Color Accessibility: Designing for Color Blindness7 min read

Private by design

Conversions run on your device in JavaScript. The values you enter are never sent over the network.