Black and White WebP Maker
Convert any image to black and white WebP format with grayscale, threshold, and dithering modes. Client-side processing, no uploads required.
About
Accurate monochrome conversion requires more than desaturation. A naive average of RGB channels produces muddy results because the human eye perceives green as roughly 2× brighter than red and 6× brighter than blue. This tool applies the ITU-R BT.601 luminance model: Y = 0.299R + 0.587G + 0.114B. For true 1-bit black and white output, threshold binarization alone creates harsh banding in smooth gradients. Floyd-Steinberg error diffusion distributes quantization error to neighboring pixels, producing a halftone illusion of tonal range using only two values. All processing runs client-side on the Canvas API. No image data leaves your browser.
Output is encoded as WebP, which achieves 25 - 35% smaller files than equivalent-quality JPEG for photographic content (Google, 2023). Note: WebP encoding quality parameter has no effect in lossless mode. For monochrome line art and dithered images, lossless mode typically produces smaller files than lossy at high quality settings. This tool approximates perceptual luminance; it does not apply ICC color profile corrections from the source image.
Formulas
Perceptual luminance from RGB channels (ITU-R BT.601):
Where Y is the resulting luminance value (0 - 255), R, G, B are the red, green, and blue channel values of each pixel.
Threshold binarization for pure black and white:
Where P is the output pixel value and T is the user-defined threshold (0 - 255).
Floyd-Steinberg error diffusion distributes the quantization error e = Y − P to four neighboring pixels:
pixel(x−1, y+1) += e ⋅ 316
pixel(x, y+1) += e ⋅ 516
pixel(x+1, y+1) += e ⋅ 116
The 4×4 Bayer ordered dither matrix:
Each pixel is compared against the corresponding matrix cell value (scaled to 0 - 255). If the luminance exceeds the matrix threshold, the pixel becomes white; otherwise black.
Reference Data
| Mode | Output Colors | Algorithm | Best For | File Size | Detail Preservation |
|---|---|---|---|---|---|
| Grayscale | 256 shades | BT.601 Luminance | Photography, portraits | Medium | Excellent |
| Threshold B&W | 2 (black/white) | Binary threshold | Text, logos, line art | Very small | Low (banding) |
| Floyd-Steinberg Dither | 2 (black/white) | Error diffusion | Photos needing 1-bit output | Small | Good (halftone) |
| Ordered Dither (Bayer) | 2 (black/white) | 4×4 threshold matrix | Retro/pixel art aesthetic | Small | Moderate (patterned) |
| WebP Lossy | - | VP8 compression | Photos, gradients | Smallest | Configurable |
| WebP Lossless | - | Predictive coding | Line art, dithered | Small - medium | Perfect |
| Luminance Coefficient | Channel | Standard | Value |
|---|---|---|---|
| YR | Red | ITU-R BT.601 | 0.299 |
| YG | Green | ITU-R BT.601 | 0.587 |
| YB | Blue | ITU-R BT.601 | 0.114 |
| YR | Red | ITU-R BT.709 (sRGB) | 0.2126 |
| YG | Green | ITU-R BT.709 (sRGB) | 0.7152 |
| YB | Blue | ITU-R BT.709 (sRGB) | 0.0722 |
| Format | Lossy | Lossless | Transparency | Animation | Browser Support |
|---|---|---|---|---|---|
| WebP | ✓ | ✓ | ✓ | ✓ | 97% |
| JPEG | ✓ | ✗ | ✗ | ✗ | 100% |
| PNG | ✗ | ✓ | ✓ | ✗ | 100% |
| AVIF | ✓ | ✓ | ✓ | ✓ | 92% |