Conversor HEX ↔ RGB ↔ HSL

Convierte colores entre los formatos HEX, RGB y HSL. Vista previa en vivo, presets rápidos, copia valores listos para CSS. 100% del lado del cliente, sin subidas.

Publicidad
Publicidad

A color converter translates colors between different format representations used in web design and digital graphics: HEX (#RRGGBB), RGB (0-255, 0-255, 0-255), HSL (hue, saturation, lightness), and HSV (hue, saturation, value). Each format describes the same color differently -- HEX is compact for CSS, HSL is intuitive for creating variations, and RGB maps directly to display hardware. This tool converts instantly as you type, entirely in your browser.

Convierte colores al instante sin salir de tu navegador

HEX, RGB, and HSL — all three formats update in real time as you type or pick. Copy CSS-ready values in one click. No uploads, no sign-up, no limits.

Real-time conversion
CSS-ready output
Gratis ilimitado

Como usarlo

  1. 1

    Elige un Color

    Escribe un valor HEX, ajusta las entradas numéricas de RGB/HSL o haz clic en un preset rápido.

  2. 2

    Mira la Vista Previa en Vivo

    La muestra de la parte superior se actualiza al instante para mostrar el color actual.

  3. 3

    Copia Cualquier Formato

    Usa el botón Copiar junto a HEX, RGB o HSL para copiar un valor listo para CSS.

¿Por qué usar este Conversor de Color?

Tres Formatos, una Sola Vista

HEX, RGB y HSL son visibles y editables al mismo tiempo — cambia uno y los demás se actualizan al instante.

Salida Lista para CSS

Los botones de copiado te dan cadenas `#RRGGBB`, `rgb(r, g, b)` o `hsl(h, s%, l%)` que se pegan directamente en CSS.

Presets Rápidos

Empieza desde la paleta predeterminada de Tailwind CSS o negro/blanco puro, luego ajusta con los deslizadores.

Publicidad

Understanding Color Formats

HEX, RGB, HSL, and HSV explained

HEX (#RRGGBB) is the most compact color format for web design. Each pair of hexadecimal digits (00-FF) represents the intensity of red, green, and blue, respectively. The value 00 means the channel is off (black), and FF means it's at full intensity. For example, #FF0000 is pure red, #00FF00 is pure green, and #FFFFFF is white. HEX is the standard format in CSS, HTML, and design tools because it's short, unambiguous, and easy to copy-paste. Shorthand notation (#RGB) exists for colors where each pair is identical, like #F00 for red.

RGB uses decimal values (0-255) for the same three channels. It's the format that display hardware natively understands -- each pixel on an LCD or OLED screen has red, green, and blue subpixels that can be set to 256 brightness levels. RGB is also used in JavaScript's canvas API (ctx.fillStyle = 'rgb(255, 0, 0)') and in image processing libraries. RGBA adds an alpha channel (0-1 or 0-255) for transparency.

HSL (Hue, Saturation, Lightness) describes colors in a way that's more intuitive for humans. Hue is the color itself, measured as an angle on the color wheel (0掳=red, 120掳=green, 240掳=blue). Saturation is how vivid the color is (0%=gray, 100%=fully colored). Lightness is how dark or light (0%=black, 50%=normal, 100%=white). HSL makes it easy to create tints (increase lightness), shades (decrease lightness), and tones (decrease saturation) of a base color. HSV (Hue, Saturation, Value) is similar but uses Value instead of Lightness -- Value=100% means the color at full brightness, while Lightness=100% means white.

Publicidad

Cuándo usar cada formato

Use HEX for CSS and HTML -- it's the most widely supported format and the shortest to write. Use RGB when you need to programmatically manipulate color channels (e.g., mixing two colors by averaging their RGB values) or when you need alpha transparency (rgba()). Use HSL when you need to create color variations -- for example, generating a button's hover state by increasing lightness by 10%, or creating a monochromatic color scheme by keeping hue constant and varying saturation and lightness.

HSL is particularly powerful in CSS custom properties (CSS variables). You can define -- hue: 210 and then use hsl(var(-- hue), 70%, 50%) throughout your stylesheet. Changing a single variable updates the entire color scheme -- impossible with HEX or RGB without recalculating every value. This is why modern CSS frameworks like Tailwind v4 are moving toward HSL-based color systems.

Publicidad

Casos de Uso Comunes

Diseñar con HSL

Construye una paleta de colores eligiendo un tono base y ajustando la luminosidad — mucho más fácil en HSL que en RGB.

Convertir Colores de Figma a CSS

Figma suele mostrar HEX; CSS a veces necesita RGB o HSL (para `color-mix` u opacidad). Obtén la cadena exacta en un clic.

Comprobación de Accesibilidad

Combina esta herramienta con el Comprobador de Contraste para verificar que tus elecciones de color cumplen los requisitos WCAG.

Ajustar Temas

Cambia rápidamente un preset de Tailwind por un color de marca personalizado y copia el HEX resultante en tu configuración.

¿Cómo se compara con otros conversores de color?

Una comparación lado a lado de herramientas populares de conversión de color.

CaracterísticaNovaToolsRapidTablesW3Schools
HEX 鈫?RGB 鈫?HSL 鈫?HSVTodos los formatosLimitado
Vista previa en tiempo realInstantáneoBotón enviar
Color picker integrationEyeDropper API
Privacidad (sin subida)100% localServer-side
Copy CSS-ready values
Funciona sin conexión

La mayoría de conversores de color en línea procesan las conversiones en su servidor. Nuestra herramienta realiza todos los cálculos en tu navegador — tus valores de color nunca se transmiten ni almacenan.

Preguntas frecuentes

¿Qué formatos de color son compatibles?
HEX (p. ej. `#2563EB`), RGB (p. ej. `rgb(37, 99, 235)`) y HSL (p. ej. `hsl(217, 83%, 53%)`). Los tres se actualizan simultáneamente cuando cambias cualquier valor.
¿Cuál es la diferencia entre RGB y HSL?
RGB describe un color por sus componentes rojo, verde y azul. HSL lo describe por tono (ángulo en la rueda de colores), saturación (intensidad) y luminosidad. HSL es más intuitivo para los diseñadores porque puedes cambiar la luminosidad sin recalcular los demás.
¿La herramienta admite la abreviatura HEX de 3 dígitos?
Sí. Escribir `#fff` se expande automáticamente a `#FFFFFF`. La salida siempre usa el formato de 6 dígitos para máxima compatibilidad.
¿Puedo copiar valores listos para CSS?
Sí. El botón Copiar junto a cada formato te da `#2563EB`, `rgb(37, 99, 235)` o `hsl(217, 83%, 53%)` — listos para pegar directamente en CSS.
¿Qué pasa si escribo un valor HEX no válido?
El campo HEX es de texto libre, así que puedes escribir cualquier cosa, pero los valores RGB y HSL solo se actualizan cuando el HEX es válido. Esto te permite experimentar sin perder tu color anterior.
How do I convert a Tailwind CSS color to RGB or HSL?
Simply type the Tailwind HEX value into the HEX field (e.g., `#2563EB` for `blue-600`). The RGB and HSL values will update instantly, and you can copy them with one click. This is useful when you need to use a Tailwind color in a context that requires RGB or HSL — for example, `color-mix(in srgb, rgb(37, 99, 235) 50%, transparent)` or `hsl(217, 83%, 53% / 0.5)` for opacity. You can also use the built-in Tailwind preset palette to start from any standard Tailwind color.
¿Puedo usar esta herramienta para crear una paleta de colores?
Yes. HSL is particularly well-suited for palette generation because you can fix the hue and vary lightness to create tints and shades of the same color. For example, set hue to 217 and saturation to 83%, then create five variations by changing lightness to 20%, 40%, 53%, 70%, and 90%. Each variation can be copied as a HEX value. Pair this tool with the Contrast Checker to verify that your text-background combinations meet WCAG accessibility standards.
¿Es esta herramienta precisa para trabajo de diseño profesional?
Yes. The conversion math follows the W3C CSS Color Module Level 4 specification, which is the same standard that browsers use internally. This means the values you copy from this tool will render identically in browsers, design tools like Figma and Sketch, and image editors like Photoshop. The tool does not apply gamma correction or color space conversion (sRGB to Display P3), so all values are in the standard sRGB color space, which is the default for web design.

Su privacidad es nuestra prioridad

Esta herramienta se ejecuta completamente en su navegador. Sus archivos no se suben, almacenan ni analizan.

  • No subimos, almacenamos ni analizamos sus archivos.
  • Todo lo que procesa permanece en su dispositivo.
  • No hay procesamiento del lado del servidor, ni almacenamiento en la nube, ni análisis.

Incluso si su conexión a internet se cae, sus archivos permanecen seguros.

También te podría gustar

Guias utiles

Publicidad