Skip to content
Back to skills

Color Palette Extractor

ASecurity

Extract dominant colors from images, generate color palettes, and export as CSS, JSON, or ASE with K-means clustering.

  • 99 stars
  • 0 votes
  • 0 copies
  • 0 views
  • Added February 7, 2026
data-aipythongobash

Works with

  • cli

Security analysis

A100/100

Pro scans all 3 files and shows the line behind each finding

Scanned February 12, 2026

npx -y skills add dkyazzentwatwa/chatgpt-skills --skill color-palette-extractor --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Color Palette Extractor?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Color Palette Extractor
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/dkyazzentwatwa-color-palette-extractor/badge)](https://www.skillsdirectory.com/skills/dkyazzentwatwa-color-palette-extractor)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: color-palette-extractor
description: Extract dominant colors from images, generate color palettes, and export as CSS, JSON, or ASE with K-means clustering.
---

# Color Palette Extractor

Extract dominant colors from images and generate color palettes with multiple export formats.

## Features

- **Dominant Colors**: Extract N most dominant colors using K-means
- **Color Schemes**: Generate complementary, analogous, triadic schemes
- **Multiple Formats**: Export as CSS, JSON, ASE (Adobe Swatch), ACO (Photoshop)
- **Color Analysis**: RGB, HEX, HSL, HSV values
- **Visualization**: Palette swatches, color distribution charts
- **Batch Processing**: Extract palettes from multiple images
- **Similarity Matching**: Find similar colors across palettes

## Quick Start

```python
from color_palette_extractor import ColorPaletteExtractor

extractor = ColorPaletteExtractor()

# Extract colors
extractor.load('image.jpg')
palette = extractor.extract_colors(n_colors=5)

# Export
extractor.export_css('palette.css')
extractor.export_json('palette.json')
extractor.save_swatch('swatch.png')
```

## CLI Usage

```bash
# Extract 5 colors
python color_palette_extractor.py --input image.jpg --colors 5 --output palette.json

# With CSS export
python color_palette_extractor.py --input image.jpg --colors 8 --css palette.css --swatch swatch.png

# Batch mode
python color_palette_extractor.py --batch images/ --colors 5 --output palettes/
```

## Dependencies

- pillow>=10.0.0
- scikit-learn>=1.3.0
- numpy>=1.24.0
- matplotlib>=3.7.0

Files in this skill

  • SKILL.md1.5 KB
  • scripts/color_palette_extractor.py7 KB
  • scripts/requirements.txt67 B

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.