Image Brightness & Contrast Adjuster

Adjust image brightness and contrast in browser. Real-time preview, no upload needed.

Was this tool helpful? Rate it:

Adjust image brightness and contrast online

The MavexTech Brightness & Contrast Adjuster lets you lighten, darken, punch up or soften a photo straight in your browser. Load an image, drag the two sliders between −100 and +100, and download the corrected PNG. Nothing is uploaded: the calculation runs on your device using the canvas element, so it works for private documents, ID scans and client photos alike.

Brightness adds the same amount to every red, green and blue value, moving the whole picture lighter or darker. Contrast stretches values away from the middle grey (128) or squeezes them toward it, which makes the gap between shadows and highlights bigger or smaller. A dull, foggy phone photo usually needs more contrast; an underexposed indoor shot usually needs more brightness.

How to use it

  1. Upload an image — JPG, PNG, WebP or any format your browser can display.
  2. Move the Brightness slider. Positive values lighten, negative values darken. The number next to the label shows the exact setting.
  3. Move the Contrast slider. Positive values add punch, negative values flatten the image.
  4. Use Reset to return both sliders to 0 and see the original again.
  5. Download PNG — the file adjusted.png has the same pixel dimensions as your original.

The maths behind the sliders

For each colour channel of each pixel the tool does two steps, in this order:

  1. Brightness: v = value + B, where B is the brightness slider (−100 to +100).
  2. Contrast: v = F × (v − 128) + 128, where the contrast factor is F = 259 × (C + 255) / (255 × (259 − C)) and C is the contrast slider.

The result is clamped to 0–255 and rounded. This is the classic contrast-correction formula used in many tutorials and simple editors. Its useful property is that mid-grey (128) never moves when only contrast changes, while values further from the middle move more. The table shows how the factor grows:

Contrast sliderFactor FValue 64 becomesValue 128 becomesValue 192 becomes
-1000.439100128156
-750.54793128163
-500.67485128171
-250.82375128181
01.00064128192
251.21550128206
501.48233128223
751.82211128245
1002.2680128255

At +100 the factor is above 2, so a value of 64 drops to 0 — deep shadows become pure black. At −100 the factor is about 0.44, so the whole range is squeezed into roughly 100–156 and the picture looks grey and hazy. Alpha (transparency) is not changed.

Example results

We ran the live tool on a test image with three colour patches and read back the pixel values. They match the formula exactly:

BrightnessContrastBrick red rgb(200, 50, 50)Mid grey rgb(128, 128, 128)Sand rgb(240, 220, 180)
+300rgb(230, 80, 80)rgb(158, 158, 158)rgb(255, 250, 210)
-300rgb(170, 20, 20)rgb(98, 98, 98)rgb(210, 190, 150)
0+50rgb(235, 12, 12)rgb(128, 128, 128)rgb(255, 255, 205)
+20+30rgb(244, 55, 55)rgb(153, 153, 153)rgb(255, 255, 219)
-30-50rgb(156, 55, 55)rgb(108, 108, 108)rgb(183, 170, 143)
+50+50rgb(255, 86, 86)rgb(202, 202, 202)rgb(255, 255, 255)

Two things stand out. First, brightness is applied before contrast, so +20 brightness with +30 contrast pushes mid-grey to 153, not 148: the 20 extra levels are themselves stretched by the contrast factor (about 1.26). Second, light colours run into the 255 ceiling quickly — sand at +50/+50 becomes rgb(255, 255, 255) pure white in all three channels — and that lost highlight detail cannot be recovered afterwards.

Worked example: fixing a dark indoor photo

Suppose a face in a dim room has skin values around rgb(90, 60, 50) and the background sits near 30. Brightness +40 lifts the skin to rgb(130, 100, 90) and the background to 70. That looks flat, so add contrast +20: F = 259 × 275 / (255 × 239) ≈ 1.169. The skin red channel becomes 1.169 × (130 − 128) + 128 ≈ 130, green becomes 1.169 × (100 − 128) + 128 ≈ 95, and the background falls to about 60. The face is brighter, the background a little deeper, and the subject separates from it.

Recommended starting points

  • Underexposed photo: brightness +20 to +40, then contrast +5 to +15 to restore depth.
  • Hazy landscape or photo through glass: brightness 0, contrast +20 to +35.
  • Harsh midday shot: contrast −10 to −25, brightness −5 if the sky is blown out.
  • Scanned document with grey paper: brightness +15 to +30 and contrast +40 to +60 makes paper whiter and text darker. For a pure two-colour result, try the Black & White converter.
  • Dreamy, faded look: contrast −30 with brightness +10, optionally followed by the Sepia filter at low intensity.

Tips

  • Make small moves. Changes of 10–20 are often enough; large values clip highlights or shadows permanently.
  • Watch the brightest and darkest areas, not the middle. Clouds, white shirts and black hair show clipping first.
  • Judge on a normal screen brightness. Phones on full brightness make images look lighter than they are.
  • Keep your original file — the download is a new image, and clipped areas cannot be brought back from it.
  • For web use, run the PNG through the Image Compressor afterwards; a lossless PNG of a phone photo can be large.

Limitations

  • Adjustments apply to the whole image equally. There are no curves, levels, shadows/highlights or selective (masked) edits.
  • All three colour channels get the same change, so this tool does not fix colour casts such as a yellow tungsten tint. Saturation is not adjustable here.
  • The canvas works with 8 bits per channel, so heavy edits on smooth gradients (sky, studio backdrops) can show visible banding.
  • Output is PNG only, and EXIF metadata from the original (camera, date, GPS) is not carried over.

Frequently Asked Questions

What is the difference between brightness and contrast?

Brightness shifts every value up or down by the same amount, so the whole image gets lighter or darker. Contrast changes how far values are from mid-grey, so shadows and highlights move apart or closer together while mid-grey stays put.

What formula does this tool use for contrast?

It uses factor F = 259 × (C + 255) / (255 × (259 − C)) and then new value = F × (value − 128) + 128, applied after brightness and clamped to 0–255.

Which is applied first, brightness or contrast?

Brightness first, then contrast. That means the brightness shift is also stretched by the contrast factor; for example brightness +20 with contrast +30 turns mid-grey 128 into 153.

Can I fix an overexposed photo?

Only partly. Lowering brightness or contrast darkens areas that still have detail, but parts that were already pure white in the original stay a flat tone because there is no information left in them.

Does the tool reduce image quality?

The download is a lossless PNG at the original size, so no compression is added. Quality is only lost where values are clipped at 0 or 255 or where strong edits create banding.

Is my image uploaded anywhere?

No. The image is processed in your browser and the PNG is generated on your device.

Can I adjust saturation or colour balance here?

No, this tool handles brightness and contrast only. For colour changes you can use the Grayscale, Sepia or Color Inverter tools, or a full editor for saturation and white balance.

Related tools

Image Sepia · Image Color Inverter · Image Compressor · Image Grayscale · Image to Black & White

Copied