Image Histogram
Inspect brightness and RGB distribution in an image
Image Histogram — what it does
Plot the tonal distribution of an image — overall brightness or the individual red, green and blue channels — alongside brightness statistics. The histogram is the objective read on exposure that your eye cannot give you, because perception adapts to whatever screen and lighting you happen to be sitting in.
Worked example
Three synthetic gradient fixtures read in Brightness mode and then RGB mode; the statistics line under the chart is what the page printed. All three are built from the same gradient, which is why they share an average.
| Image | Channel | Statistics line |
|---|---|---|
| photo-1600x1200.png (1600 × 1200) | Brightness | Average brightness: 126.5 / 255 · Pixels sampled: 607,500 |
| logo-400x400.png (400 × 400) | Brightness | Average brightness: 126.5 / 255 · Pixels sampled: 160,000 |
| banner-1200x300.png (1200 × 300) | RGB | Average brightness: 126.5 / 255 · Pixels sampled: 202,500 |
607,500 is 900 × 675, not 1600 × 1200: images wider than 900 px are scaled down to 900 px wide before sampling. The 400 px logo is sampled in full.
When this tool helps
- Diagnosing whether a photo is genuinely underexposed or just displayed on a dim screen.
- Checking for clipping — pixels crushed to pure black or blown to pure white with no detail left.
- Judging whether an image has enough tonal range to survive printing.
How to use it
- Choose the image.
- Select the channel: brightness, red, green or blue.
- Read the distribution shape.
- Check the brightness statistics beneath it.
Accuracy, limits, and good practice
- A spike hard against the left or right edge means clipped shadows or highlights, where the data is gone rather than merely dark or bright.
- There is no correct histogram shape — a night scene should sit left and a snow scene right. Judge it against the subject, not against a bell curve.
- A histogram pushed to one side but not clipped is fixable with the image filters tool; a clipped one is not.
Frequently asked questions
What do the RGB channels tell me?
Colour balance. One channel clipping while others do not usually indicates a colour cast or a strongly saturated subject.
Should the histogram be centred?
Not necessarily. Centring is a rule of thumb for average scenes and wrong for deliberately dark or bright ones.
Can I fix a clipped image?
Clipped areas carry no data to recover. Brightening reveals only flat grey where detail should have been.
Why is 'pixels sampled' smaller than my image?
Anything wider than 900 px is drawn at 900 px wide, with the height scaled to match, and the histogram is built from that reduced copy — a 4000 × 3000 photo is sampled as 900 × 675. Images 900 px wide or narrower are read pixel for pixel.
Does the channel selector change the numbers?
No. The selector only decides which curves are plotted — red, green, blue, all three, or luminance. The average is always the luminance (0.2126 R + 0.7152 G + 0.0722 B, rounded per pixel) and is shown to one decimal.
Related tools on this site
- Image Canvas Extender — Add custom margins and background around an image
- Convert Image Format — Convert images to JPG, PNG, or WebP
- Image to Base64 — Convert images locally in browser
Further reading: Getting images ready for the web, email and social media
Everything above runs inside this page. Image Histogram needs no account, no upload, and no server round trip — close the tab and nothing is left behind.
圖片直方圖能做什麼
繪出圖片的色調分布——整體亮度或紅、綠、藍各通道——並附上亮度統計。直方圖提供的是眼睛給不了的客觀曝光判讀,因為視覺會自動適應你當下的螢幕與環境光。
實際範例
三個合成漸層範例檔,先以「Brightness」再以「RGB」模式讀取;表中第三欄就是圖表下方印的統計列。三個檔案來自同一條漸層,所以平均值相同。
| 圖片 | 頻道 | 統計列 |
|---|---|---|
| photo-1600x1200.png(1600 × 1200) | Brightness(亮度) | Average brightness: 126.5 / 255 · Pixels sampled: 607,500 |
| logo-400x400.png(400 × 400) | Brightness(亮度) | Average brightness: 126.5 / 255 · Pixels sampled: 160,000 |
| banner-1200x300.png(1200 × 300) | RGB | Average brightness: 126.5 / 255 · Pixels sampled: 202,500 |
607,500 是 900 × 675,不是 1600 × 1200:寬度超過 900 px 的圖片會先縮到 900 px 寬再取樣;400 px 的 logo 則是逐像素讀取。
什麼時候用得上
- 判斷照片是真的曝光不足,還是只是螢幕太暗。
- 檢查是否有截斷——像素被壓成純黑或衝成純白,細節已不存在。
- 評估圖片的階調範圍是否足以承受印刷。
使用步驟
- 選擇圖片。
- 選擇通道:亮度、紅、綠或藍。
- 解讀分布形狀。
- 查看下方的亮度統計。
精確度、限制與實務建議
- 緊貼左端或右端的尖峰代表暗部或亮部被截斷,那裡的資料已經消失,不只是偏暗或偏亮。
- 沒有所謂正確的直方圖形狀——夜景本該偏左、雪景本該偏右。請對照題材判斷,而不是對照鐘形曲線。
- 偏向一側但未截斷的直方圖可用圖片濾鏡救回;已經截斷的救不回來。
常見問題
RGB 通道能看出什麼?
色彩平衡。單一通道截斷而其他沒有,通常代表有色偏或主體顏色極度飽和。
直方圖應該置中嗎?
不一定。置中只是一般場景的經驗法則,對刻意的暗調或亮調作品並不適用。
被截斷的圖片救得回來嗎?
截斷區域沒有資料可還原,調亮後只會看到本該有細節的地方變成一片平灰。
為什麼「Pixels sampled」比我的圖片小?
寬度超過 900 px 的圖會先以 900 px 寬、等比例的高度畫一次,直方圖從這份縮圖算起——4000 × 3000 的照片會被當成 900 × 675 取樣。寬度 900 px 以內的圖則逐像素讀取。
切換頻道會改變數字嗎?
不會。下拉選單只決定畫哪些曲線:紅、綠、藍、三者一起或亮度。平均值永遠是亮度(0.2126 R + 0.7152 G + 0.0722 B,逐像素四捨五入),顯示到小數一位。
本站相關工具
- 圖片畫布擴展 — 在圖片四周增加自訂邊距與背景
- 圖片格式轉換 — 將圖片轉換成 JPG、PNG 或 WebP
- 圖片轉 Base64 — 在瀏覽器中本地轉換圖片
延伸閱讀: 為網頁、電子郵件與社群媒體準備圖片
以上步驟全部在這個頁面內完成,圖片直方圖 不需要註冊、不上傳檔案、也不經過伺服器,關閉分頁後不會留下任何資料。