CLAHE

What Is CLAHE?

CLAHE stands for Contrast Limited Adaptive Histogram Equalization. It is an image processing technique that improves local contrast by adjusting small regions of an image separately while limiting excessive amplification.

The method is useful when different parts of an image have different lighting or contrast. It builds on adaptive histogram equalization, adding a limit designed to reduce the overamplification of noise in relatively uniform regions.

For image workflows, CLAHE offers a configurable way to make existing tonal differences more visible. It cannot restore details that were never captured or were lost through clipping.

How CLAHE Works

Calculate Local Contrast Adjustments

CLAHE divides the image into regions called tiles. For each tile, it calculates a histogram describing how frequently different intensity values occur.

It then uses that local distribution to create a mapping from input intensities to output intensities. Different areas can receive different adjustments, allowing a shadowed region to be treated differently from a brighter one.

Limit Histogram Peaks5

Before calculating the mapping, CLAHE limits histogram bins that exceed a specified threshold. The excess counts are redistributed across other bins.

This modifies the resulting intensity transformation and limits how aggressively local differences are amplified. The process clips histogram counts, rather than simply cutting off bright pixels in the source image.

Blend Neighboring Mappings

Applying unrelated adjustments to adjacent tiles could create visible boundaries. CLAHE typically uses bilinear interpolation between neighboring mappings to smooth those transitions.

This produces a continuous result while retaining the local nature of the adjustments.

Important CLAHE Settings

Clip Limit

The clip limit controls the strength of contrast limiting. Higher limits generally permit stronger enhancement, but can also make noise more visible.

However, this parameter scales differently between implementations. A setting from one library shouldn’t be transferred to another without checking how that library defines it.

Tile Grid

The tile configuration determines the spatial scale of adaptation. Smaller regions produce more localized adjustments; larger regions consider broader areas.

Check whether an API expects tile dimensions or tile counts. In OpenCV, tileGridSize specifies the number of tiles across the image. An 8-by-8 grid therefore contains 64 tiles, rather than tiles measuring eight pixels each.

Color Handling

For color images, a common approach is to apply CLAHE to the lightness channel in a space such as CIELAB, then convert back to RGB. Color should still be reviewed after processing, especially for product imagery.

CLAHE vs. Other Histogram Equalization Methods

Method Adjustment scope Main consideration
Global histogram equalization One histogram for the whole image A single mapping may suit some regions poorly
Adaptive histogram equalization Local regions Can strongly amplify noise in uniform areas
CLAHE Local regions with contrast limiting Balances local enhancement against amplification

Why CLAHE Matters

Imagine a picture of a black leather backpack set against a brightly illuminated wall. A global adjustment might improve the wall’s appearance without making the stitching easier to distinguish.

CLAHE could help reveal tonal differences around the backpack’s seams. However, an aggressive configuration might also emphasize grain in the background or exaggerate the leather texture.

For an automated asset workflow, the practical question is whether the adjustment improves the intended output consistently across representative images.

QUICK TIPS
Jen Looper
Cloudinary Logo

Here are some tips to better understand CLAHE:

  1. Start conservatively
    Increase enhancement only where the result provides a clear benefit.
  2. Inspect smooth regions
    Check backgrounds and shadows for newly emphasized noise.
  3. Confirm tile semantics
    Distinguish tile counts from pixel dimensions when configuring an API.
  4. Review color-sensitive content
    Inspect product colors, skin tones, and neutral surfaces after processing.
  5. Validate batch settings
    Test bright, dark, textured, and noisy images before applying one configuration broadly.
Last updated: Nov 17, 2026
★★★★★
4.7 (22 reviews)
Talk to Sales Talk to Sales