Brighten a dark photo, and check the blown highlights with numbers
The image brightness and contrast adjuster changes a photo with two sliders, shows the result side by side with the original, and saves it at the original size. Every time you move a slider, the histogram below redraws the brightness distribution of the original and the adjusted photo on top of each other, and the mean brightness, contrast (RMS), blown highlights and crushed shadows are counted again. So you can decide how far to go by the numbers instead of by eye.
The example on the first screen is a backlit park photo underexposed by 2 stops. Its mean brightness is 28%, far darker than middle gray (46.6%). Auto adjust picked brightness +32 and contrast +27 for it, which brings the mean brightness to 45% and the contrast (RMS) from 13.2 to 25.4. Crushed shadows are then 0.37% and blown highlights 0%. The photo is processed only inside this browser and is never sent to a server.
When to use it
- A backlit portrait with a dark face: when you shoot someone with the sun behind them, the bright sky and the shaded face share one frame and the face comes out dark. Raise the brightness first: the face gets lighter, while the sky, which is already bright, only creeps slowly toward white and clips far less.
- Dull shots taken indoors or in the evening: if the mean brightness has dropped below 30%, start with Auto adjust, then add contrast until the bars stop piling up at the left end of the histogram.
- Hazy or overcast landscapes that look washed out: the brightness is fine, but the gap between light and dark areas is small. If the histogram is bunched narrowly in the middle, raising only the contrast is enough to make the picture crisper.
- Documents, receipts and whiteboards shot with a phone: when the paper comes out gray and the writing looks faint, a large contrast boost pushes the background toward white and the text toward black. Here it does not matter if the background blows out.
- A photo that is too bright, to calm it down: lowering the brightness leaves pure white (255) as it is and pulls darker values down more the darker they are. At brightness −25, 250 only drops to 245 while 128 becomes 85, so a white background stays almost unchanged and only what is in the picture calms down.
How to use it
- Press "Open my photo" or drag a photo onto the work area. A copied photo can also be pasted with Ctrl+V (⌘+V on a Mac).
- In the sentence below, check how much darker (or brighter) the mean brightness is than middle gray. The end of the sentence already shows the values Auto adjust would pick.
- Press Auto adjust, or move the brightness slider first and the contrast slider second. With the keyboard, the left and right arrow keys move a slider by 1.
- Drag the handle on the photo left and right to compare the original (left) with the adjusted photo (right). Turn on "Show clipped areas" to paint blown highlights red and crushed shadows blue.
- Pick a format (JPG or PNG) and press "Save photo". The saved file keeps the original name with -edited added at the end.
The brightness slider leaves black and white alone
The brightness slider value b (−100 to +100) bends each R, G and B value x (0 to 1) along the curve below. 0 stays 0 and 1 stays 1, and only what lies between is curved. So raising the brightness never clips anything that was not already white, and it never lifts true black into gray. The curve for lowering brightness is the mirror image of the curve for raising it by the same amount.
k = 2b ÷ 25 − 1 · new value = (1 + k) × x ÷ (1 + k × x)
The web standard CSS brightness(), by contrast, is a straight line that multiplies every value by the same number, so at 150% every value of 170 or more becomes 255 (white). Adobe's Photoshop help likewise says the Use Legacy method, which shifts all pixels by the same amount, can lose detail in bright and dark areas and is not recommended for photographs. The table below shows where the values 0 to 255 end up for each slider setting.
| Original value | 0 | 32 | 64 | 128 | 192 | 224 | 255 |
|---|---|---|---|---|---|---|---|
| Brightness +25 | 0 | 57 | 102 | 170 | 219 | 238 | 255 |
| Brightness +50 | 0 | 93 | 146 | 204 | 236 | 246 | 255 |
| Brightness +75 | 0 | 136 | 186 | 227 | 245 | 251 | 255 |
| Brightness −25 | 0 | 17 | 37 | 85 | 154 | 200 | 255 |
| Brightness −50 | 0 | 9 | 20 | 51 | 110 | 164 | 255 |
| CSS brightness(150%) | 0 | 48 | 96 | 192 | 255 | 255 | 255 |
As the table shows, brightness +50 lifts dark values a lot (32 → 93) and bright values only a little (224 → 246). That rescues a face lost in darkness or an object in shadow while protecting the sky. Keep in mind that if you pull up a lot of very dark area, the noise and JPG compression blocks hidden in it get brighter too.
The contrast slider spreads values around the middle, and the ends get clipped
The contrast slider value c stretches or squeezes the brightness-adjusted values around 50% gray. The formula is the same straight line as CSS contrast(): when the slope s is above 1, light areas get lighter and dark areas get darker. But values pushed out of range stop at 0 or 255, so different brightnesses in that stretch merge into one black or one white. In photography this is called clipping, and highlights that have blown out cannot be recovered.
s = 2c ÷ 50 · new value = (value − 0.5) × s + 0.5, set to 0 if below 0 and to 1 if above 1
| Contrast value | Slope s | Range that survives unclipped (value after brightness) | Result |
|---|---|---|---|
| +25 | 1.41 | 14.6% to 85.4% | 14.6% at each end merges into black or white |
| +50 | 2.00 | 25% to 75% | Everything below 25% brightness turns black, everything above 75% turns white |
| +100 | 4.00 | 37.5% to 62.5% | Splits almost into pure black and white (for documents and text) |
| −50 | 0.50 | Everything survives | Black lifts to 25% gray and white drops to 75% gray, so the picture looks hazy |
That is why it is safer to set the brightness first and add contrast afterwards. On the example photo, contrast +50 with no brightness change actually lowers the mean brightness to 16% and crushes 35.9% of the pixels. With brightness +32 first and contrast +27 added, which is what Auto adjust does, crushed shadows stay at 0.37%.
How to read the histogram
The horizontal axis of the histogram is the pixel brightness value (luma) from 0 to 255, and the vertical axis is the share of the photo's pixels with that brightness. Luma is computed with the broadcast standard BT.601 formula Y′ = 0.299 R′ + 0.587 G′ + 0.114 B′, which reflects the fact that green looks brighter to the eye than red or blue of the same strength. The gray bars are the original, and the darker outlined bars are the photo as you have adjusted it now.
- Bars piled on the left mean a dark photo, and bars piled on the right mean a bright one. The dotted line in the middle is middle gray (46.6%).
- Bars bunched narrowly in the middle mean low contrast. Raising the contrast spreads the bars out to both sides.
- A tall bar in the far-left (0) or far-right (255) column means that many pixels are crushed or blown out. The exact share is in the number boxes on the right.
- The triangles on the strip under the graph mark the mean brightness: the faint triangle is the original and the dark triangle is the adjusted photo.
The graph height is set by the tallest column excluding the two end columns, so if an end column is very tall, it is drawn cut off at the top. Hover over the graph and the brightness range at that position, with the original and adjusted shares, appears under it.
How Auto adjust picks its values
Auto adjust chooses the values in two steps. First, for brightness, it looks within −75 to +75 for the whole number that brings the adjusted photo's mean luma closest to middle gray. Middle gray is CIE lightness L* 50, which people perceive as half of full brightness, converted to an sRGB value: 46.6% (about 119 out of 255). If the original mean is already within ±4 percentage points of this value, or if changing the brightness would not change the mean at all, as in an all-black picture or one with only black and white, the brightness is left unchanged.
Next, for contrast, at that brightness it picks the largest value from 0 to +50 at which the pixels whose luma is in the darkest 0.5% and the brightest 0.5% are not pushed beyond 0 and 255. Auto adjust never lowers the contrast. Both steps are calculated on the same on-screen copy as the number boxes below.
Because this method moves the average toward middle gray for any photo, it gets photos wrong when they are meant to be bright or meant to be dark. Snow scenes and product shots on a white background turn dull and dark, while night skies, fireworks and stage shots become far too bright. For these, press Auto adjust and then move the brightness slider back yourself.
What the number boxes mean
- Mean brightness: the average luma of all pixels, shown from 0 to 100%. Fully transparent pixels are not counted.
- Contrast (RMS): the standard deviation of the luma on a 0 to 100 scale. It measures how widely pixel brightness is spread around the average, and Peli (1990) set it out as a contrast measure for complex images. The larger the value, the bigger the gap between light and dark areas. The example photo goes from 13.2 in the original to 25.4 after Auto adjust.
- Blown highlights and crushed shadows: the share of pixels whose luma has become 255 (pure white) or 0 (pure black). If it rises by more than 0.5 percentage points over the original, the box border changes to the accent color and the sentence below suggests lowering the contrast. Because this is based on luma, a saturated-color pixel where only one of R, G and B has reached 0 or 255 is not counted. In the example photo's Auto adjust, crushed shadows by luma are 0.37%, but pixels with even one channel at 0 are 7.5%.
The number boxes and the histogram are counted on the on-screen copy (about 1.44 million pixels). A photo at or below that size is counted on the same pixels as the saved file, while a larger photo is reduced first and neighboring pixels get blended, so the share of clipped areas can come out slightly lower than in the saved file. The table below shows the values in the number boxes when the example photo is changed to various settings.
| Brightness · contrast | Mean brightness | Contrast (RMS) | Blown highlights | Crushed shadows |
|---|---|---|---|---|
| 0 · 0 (original) | 28% | 13.2 | 0% | 0% |
| +32 · +27 (Auto adjust) | 45% | 25.4 | 0% | 0.4% |
| +50 · 0 | 57% | 18.0 | 0% | 0% |
| 0 · +50 | 16% | 15.6 | 0% | 35.9% |
| +50 · +50 | 64% | 35.2 | 9.8% | 1.3% |
Raising only the brightness to +50 lifts the mean to 57% and the contrast (RMS) rises a little to 18.0, but that is flatter than Auto adjust (25.4). Raising the brightness further drags the dark values up and the contrast actually falls (16.0 at +75, 12.0 at +100), so the photo looks hazy and grayish. Raising both brightness and contrast to +50, on the other hand, blows out 9.8% of the pixels, mostly in the sky. Watch the number boxes and the comparison with the original together, and stop somewhere between those two settings.
Saved size, format and photo information
- Size: for fast redrawing, the screen shows a copy reduced to about 1.44 million pixels, but when you save, the original is read again and the same calculation is run on it. If the original is larger than 4,096 × 4,096 (about 16.78 million pixels), it is reduced to fit within that size. This is because the canvas limit on iOS devices is 4,096 × 4,096. A 12-megapixel phone photo (4,032 × 3,024) is saved at its original size.
- Format: JPG is saved at quality 92%, with transparent areas filled with white. PNG keeps transparency and loses no quality, but a photo becomes several times larger than as a JPG. The format preselected is PNG when the original is a PNG or GIF or has transparent pixels, and JPG otherwise.
- Photo information (Exif): the saved file carries no Exif data such as shooting date, device or location. The orientation of a photo taken in portrait was already applied by the browser when it opened the photo, so the saved photo has the same orientation you saw on screen.
This tool does not use the browser's canvas filter feature and changes the pixel values directly. The canvas filter only works in Safari and iPhone Safari from version 18, and only after a setting is turned on, so the same slider values could give different results in different browsers. Because the tool does the calculation itself, Chrome, Safari, Firefox and phones all apply the same conversion table to the pixels.
Common mistakes
- Raising the contrast a lot first: on a dark photo, raising the contrast first actually lowers the mean and crushes all the shadows at once. Set the brightness first.
- Raising only the brightness by a lot: on the example photo the contrast (RMS) rises up to brightness +50, and after that the dark values get dragged up and it falls (12.0 at +100). Once the contrast (RMS) number starts to drop, stop raising the brightness and add a little contrast.
- Trying to bring back a blown-out sky by lowering the brightness: anything that was 255 in the original has no information, so it only turns gray and the clouds do not return. If "Blown highlights" in the original's number box is high, it is better to pick another photo.
- Judging on a screen in night mode or at low brightness: when the screen is dim, the photo feels dark too and it is easy to brighten it too much. Look at the mean brightness number and the histogram together.
- Saving as JPG and reopening it many times: compression loss builds up with every save. If a photo needs several rounds of editing, save the in-between versions as PNG.
Limits
- Brightness and contrast use the same curve across the whole photo. There is no way to change only part of it, such as darkening just the sky or lightening just a face, and there is no color temperature or saturation control.
- The same curve is applied to the R, G and B channels, so a large contrast boost makes colors stronger and a large brightness boost makes them slightly paler.
- The calculation uses sRGB values as they are. A photo stored in Display P3, like an iPhone photo, is converted to sRGB by the browser when it is read, so very saturated colors may be saved less saturated than in the original.
- HEIC photos open only in Safari 17 or later. In Chrome, Edge and Firefox, convert them to JPG first. Files larger than 60 MB and photos over 100 megapixels are not opened.
- The clipped-area share, the clipped-area marking and the contrast chosen by Auto adjust are all based on luma. A saturated color with only one clipped channel is neither counted nor painted.
- For animated GIF and WebP files, only the first frame is changed.
Basis: the relevant sentences in the documents below were checked on 2026-10-20. The table values were calculated with this tool's own formulas, and the example photo figures were calculated directly on the example photo (1,440 × 960) on the first screen.
Sources
- 01W3C — Filter Effects Module Level 1brightness() is a straight line that multiplies the input by a constant (feFuncR type="linear" slope=amount); contrast() uses slope=amount, intercept=−(0.5 × amount) + 0.5
- 02MDN — CanvasRenderingContext2D: filter propertyCompatibility table: Safari and iOS Safari support it from version 18, and only when the 'Canvas Filters' setting is turned on
- 03Adobe Photoshop — Apply brightness and contrast adjustmentUse Legacy shifts all pixel values by the same amount, which can lose detail in bright and dark areas, and is not recommended for photographs
- 04Cambridge in Colour — Camera Histograms: Tones & ContrastAreas overexposed to pure white cannot have their detail recovered; this is called clipped or blown highlights
- 05Wikipedia — Luma (video)CCIR 601 (BT.601) luma formula Y′ = 0.299 R′ + 0.587 G′ + 0.114 B′
- 06Peli, E. (1990). Contrast in complex images. JOSA A 7(10), 2032–2040RMS contrast = standard deviation of pixel brightness
- 07W3C — CSS Color Module Level 4sRGB transfer function and CIE Lab conversion: L* 50 → relative luminance 0.18419 → sRGB 0.46633 (118.9 out of 255)
- 08MDN — <canvas>: Maximum canvas sizeThe maximum size differs between browsers, and iOS devices allow 4,096 × 4,096 pixels
- 09MDN — image-orientationDefault value from-image: the image is rotated as needed using the EXIF information in it
- 10Wikimedia Commons — Riding a bike in the park (Unsplash).jpgSource of the example photo (Fritz Bielmeier, CC0 1.0). This tool reduces it to 1,440 × 960 and lowers the exposure by 2 stops
Frequently asked questions
How much should I raise the brightness to lighten a dark photo?
It depends on the photo, so the easiest way is to go by the mean brightness number. This tool compares the mean brightness with middle gray (46.6%) and previews the values Auto adjust would pick. For example, the example photo has a mean brightness of 28%, and Auto adjust picks brightness +32 and contrast +27, which brings the mean to 45%.
What is the difference between brightness and contrast?
Brightness shifts the whole photo lighter or darker, while contrast widens or narrows the gap between light and dark areas. In this tool, brightness leaves black and white alone and moves only the values between them, and contrast spreads values around 50% gray, so a large boost clips both ends to black and white.
I raised the brightness and the photo looks hazy. What should I do?
Raising the brightness a lot drags the dark values up too, which shrinks the gap with the bright areas. If the contrast (RMS) in the number boxes rises and then starts to fall (on the example photo, after brightness +50), stop raising the brightness and raise the contrast slider a little. Stop when the far-left column of the histogram grows tall or the share of crushed shadows rises.
Can I bring back a sky that has blown out to white?
No. Where the original is already pure white (255) there is no pattern information left, so lowering the brightness only turns it gray and the clouds do not return. If the share of blown highlights in the original's number box is high, it is better to pick another photo or shoot again.
How do I read the histogram?
The horizontal axis is the brightness value from 0 (black) to 255 (white), and the bar height is the share of pixels with that brightness. Bars piled on the left mean a dark photo, and bars bunched narrowly in the middle mean low contrast. A tall bar in an end column means that many pixels are crushed or blown out. Gray is the original and the dark outline is the photo as adjusted now.
Is my photo uploaded to a server? Is location data kept?
The photo is never sent to a server and is calculated only inside this browser. The saved file carries no Exif data such as shooting date, device or location, and a portrait photo is saved with the orientation you saw on screen.
Does saving reduce the photo's size or quality?
The size is kept as in the original. Only a photo larger than 4,096 × 4,096 (about 16.78 million pixels) is reduced to fit within that, to match the iPhone browser limit. A 12-megapixel phone photo stays as it is. JPG is saved at quality 92% and PNG is saved without loss.
Auto adjust changes my snow or night photos strangely.
Auto adjust moves the mean brightness toward middle gray, so a snow scene or a white-background shot that is meant to be bright turns darker, and a night sky or stage shot that is meant to be dark turns far too bright. For such photos, move the brightness slider back yourself after Auto adjust, or set it little by little with the sliders from the start.