颜色转换器
在 HEX、RGB、HSL、HSV 和 CMYK 颜色空间之间转换颜色,自动识别输入格式。免费、隐私、100% 客户端运行。输入 HEX、RGB 或 HSL 任一格式,即可同时获得所有五种颜色空间的值,适合前端开发、设计稿取色、印刷配色等场景。
尝试示例:
Local only
最近历史
暂无历史
使用方法
- 输入 HEX、RGB 或 HSL 格式的颜色。
- 查看所有颜色空间的转换值。
- 复制所需格式。
使用此工具的任务
检查 color contrast for WCAG accessibility compliance
Measure contrast 比率之间 foreground 和背景 colors 和验证它 meets WCAG AA 或 AAA thresholds. 任务
转换 colors between hex, RGB, HSL, and named formats
Translate 颜色值 之间 hex (#ff5733), rgb(), hsl(), 和 CSS named colors 为 use 在不同 contexts. 任务
转换 CSS to Sass/SCSS
Sass extends CSS 具有变量, nesting, mixins, 和函数. Convert plain CSS 到 SCSS 到启动 using 这些 features incrementally. 任务
生成 a color palette from a base color
Derive complementary, analogous, triadic, 和 shade/tint variants 从单个进制颜色为 设计 systems. 任务
将 RGB 颜色转换为 HEX(及反向)
在 rgb() 与 #rrggbb 表示间转换颜色值,并为 CSS 工作处理 alpha 通道。 任务
使用此工具的管道
常见问题
- Which input formats are auto-detected?
- HEX (e.g. #FF5733 or FF5733), RGB (e.g. rgb(255, 87, 51)), and HSL (e.g. hsl(11, 100%, 60%)) are auto-detected from the input.
- Which output color spaces are produced?
- HEX, RGB, HSL, HSV, and CMYK values are all returned for every valid input, one per line.
- What is the difference between HSL and HSV?
- Both use hue, saturation, and a lightness/value component. HSL's Lightness goes 0=black to 100=white regardless of saturation. HSV's Value goes 0=black to 100=the pure hue. HSV matches how humans perceive color; HSL is more intuitive for tint/shade.
- When is CMYK useful?
- CMYK is the subtractive color model used in printing. If you are preparing a design for print, convert your screen color to CMYK to preview how it will appear on paper.
- Are 3-digit HEX codes supported?
- Yes. #F00 is expanded to #FF0000, #abc to #aabbcc, following the CSS shorthand convention.
- 遇到无效输入会怎样?
- The tool reports an error and does not produce partial output. Check that your HEX has 3 or 6 hex digits, or that RGB/HSL values are within their valid ranges.