# gookit/color

🎨 Terminal color rendering library, support 8/16 colors, 256 colors, RGB color rendering output, support Print/Sprintf methods, compatible with Windows. GO CLI 控制台颜色渲染工具库，支持16色，256色，RGB色彩渲染输出，使用类似于 Print/Sprintf，兼容并支持 Windows 环境的色彩渲染

Repository: https://github.com/gookit/color
Canonical: https://ross.abutalabs.com/products/gookit-color
Homepage: https://gookit.github.io/color/
Language: Go
License: MIT
License Family: permissive
Topics: cli-color, console-color, color, terminal-colors, 256-colors, rgb-color, true-color, gookit, go-color, color-rgb, console, cli, colors, command-line, terminal
Last push: 2026-06-04T13:00:11+00:00

## Health v2 (maintenance only)
Score: 75/100 (v2, computed 2026-09-02T17:46:02.011165+00:00)
- activity 85, release rhythm 49, longevity 100
- inputs: {"age_days": 2985, "days_push": 90, "days_rel": 124, "gap_med": 246, "n_releases_24m": 2}
- flags: none
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 1606, forks 87 (observed 2026-08-28T04:05:10.429290+00:00)

## What it is
A Go library for rendering colored output in terminal/CLI applications, supporting 16-color, 256-color, and true color (RGB) modes. It offers Print/Sprintf-style APIs, HTML tag-style color markup, and works on Windows CMD and PowerShell.

## Use cases
- add colored output to a go cli tool
- print colored text in windows cmd and powershell
- render 256 color and rgb true color in terminal
- convert hex or hsl colors to rgb for terminal output
- tag-based color markup like <green>message</> in go
- respect NO_COLOR and FORCE_COLOR environment variables

## When to choose
- you are writing a Go CLI and need rich terminal colors
- you need Windows compatibility including 256/true color support
- you want a zero-dependency color library with a familiar Print/Sprintf API

## When to avoid
- your project is not written in Go
- you only need simple logging levels rather than color control
- you need TUI layout widgets rather than just color rendering

## Facets
- artifact type: library
- maturity: active
- function: cli, developer-tools, terminal-ui
- domain: developer-tools, cross-platform
- platform: go, cli, windows, cross-platform
- tags: terminal-colors, ansi-colors, true-color, 256-color, rgb-color, zero-dependency, cli-output, command-line, linux, macos

## Member repositories
- gookit/color (main) score 75

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:05:10.429290+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-30T03:51:55.730974+00:00, confidence not recorded.
  - readme: https://github.com/gookit/color (fetched 2026-08-28T04:05:10.429290+00:00, sha 5324b22e7e8e)
  - homepage: https://gookit.github.io/color/ (fetched 2026-08-29T11:23:45.013550+00:00, sha d0e79a1b1e1d)
- Data as of 2026-08-30T08:39:29.467469+00:00.
