Histogram maker from CSV
A histogram of any CSV column, in your browser. Nothing is uploaded.
Open a CSV to see its histogram
Drop it here or choose a file. The first number column opens as a histogram.
The sample: a year of made-up hourly weather in Leeds, 8,760 rows.
Tip: drop several files to compare them.
Your file never leaves your device. It is read and charted by your browser. Nothing is uploaded.
Opens as a histogram, with automatic bins
- Column
- The first number column (the one a plot shows first), every value of the whole file.
- Bins
- Automatic: NumPy’s “auto” rule, at most 500 bins of equal width from the smallest value to the largest.
- Statistics
- “Statistics” over the plot: the values counted, the number of bins and the most common range.
At a glance
- Bins
- Automatic, or 10, 20, 50, 100 or 200 bins of equal width, from the smallest value to the largest.
- Automatic
- NumPy’s “auto” rule: the narrower of the Freedman–Diaconis and Sturges bin widths, at most 500 bins.
- Edges
- Each bin holds its lower edge; the last one holds its upper edge too, as NumPy counts them.
- Counts
- How many values fall in each bin. As a table, each bin’s From, To and Count, downloadable as a CSV.
- Values
- Every value of the column, the whole file; missing ones are left out and counted.
- Other rules
- Freedman–Diaconis, Sturges or square-root bins as a table, from the Math dialog.
- Accuracy
- Bins and counts as numpy.histogram gives them, checked by our own tests.
- Processing
- Calculated in your browser. Your file is never uploaded.
- Price
- Free. No account or sign-up.
How to make a histogram from a CSV file
- Open your file. Choose a CSV, TSV, TXT, Excel, JSON, MATLAB, Parquet, HDF5 or LabVIEW TDMS file, or drop it on the tool at the top of this page. No file to hand? Click “Try a sample weather file”.
- See the histogram. The first number column opens as a histogram, with automatic bins. For another column, untick it in the list on the left and tick the one you want: the histogram is of the plot’s first column.
- Choose the bins. Open Plot settings (the sliders button in the plot’s header), then Axes, and pick Automatic or 10, 20, 50, 100 or 200 bins. “Show as a table” in the plot’s menu lists every bin, and downloads them as a CSV.
A worked example you can check
“Try a sample weather file” opens a made-up year of hourly weather in Leeds, 8,760 rows. Its first column, Leeds_Temperature, opens as a histogram of all 8,760 temperatures, from -3.33 to 21.88 °C. Click Statistics over the plot, then set 20 bins in Plot settings, and this is what you should get:
| Bins | Bin width | Most common |
|---|---|---|
| Automatic: 34 | 0.7415 °C | 502 hours, 11.5–12.24 °C |
| Set to 20 | 1.2605 °C | 814 hours, 11.8–13.06 °C |
The automatic rule gives 34 narrow bins for 8,760 values. Both show the same broad shape, highest around 12 °C with a long tail of cold winter hours; 20 wider bins smooth it, and the most common range moves with the edges.
The same in Python
With the sample file downloaded, these lines give NumPy’s answer for the same bins:
import numpy as np, pandas as pd
t = pd.read_csv("megarows-sample-leeds-hourly-weather.csv", skiprows=[1])["Leeds_Temperature"].to_numpy()
for bins in ["auto", 20]:
counts, edges = np.histogram(t, bins=bins)
k = counts.argmax()
print(f"{bins}: {len(counts)} bins of {edges[1] - edges[0]:.4f} °C, "
f"most common {edges[k]:.2f} to {edges[k + 1]:.2f} °C ({counts[k]} hours)")They print:
auto: 34 bins of 0.7415 °C, most common 11.50 to 12.24 °C (502 hours)
20: 20 bins of 1.2605 °C, most common 11.80 to 13.06 °C (814 hours)We ran them on 9 October 2026 with numpy 2.1.3, pandas 2.2.3, Python 3.12.15. A test works out the histogram on every change to the site and checks that every edge and count is NumPy’s, and that the panel’s numbers are the ones on this page. Download the sample file (CSV, 299 KB).
How the bins are chosen
Every bin has the same width, and together they run from the smallest value of the column to the largest. A value on the edge between two bins counts in the upper one; the largest value counts in the last bin. These are NumPy’s rules (numpy.histogram), so the counts match a histogram made in Python.
- Automatic (the default) uses NumPy’s “auto” rule: it works out the Freedman–Diaconis width (twice the interquartile range divided by the cube root of the count, robust to outliers) and the Sturges width (the range divided by log₂ n + 1, good for small samples), and takes the narrower. At most 500 bins are drawn (a rule that asks for more gets 500), and if a few extreme values make it ask for more than ten million, the histogram uses 100 bins instead.
- 10, 20, 50, 100 or 200 bins, from Plot settings, Axes, Bins, split the same range into that many equal parts.
For Freedman–Diaconis, Sturges or square-root bins on their own, use Bins by a rule over the plot: the Math dialog’s Histogram gives the bins as a table with the rule you pick.
Counts, the table and the statistics
The height of each bar is the number of values in that bin. Show as a table in the plot’s menu lists every bin with its From, To and Count, and its Download CSV saves exactly those rows. The statistics panel shows the values counted, the number of bins, the most common range and, when there are any, the rows with no value, which are left out.
The histogram always covers the whole file, whatever the zoom. It shows counts, not percentages or a density: to compare two files of different lengths, divide by the values counted.
Checked against NumPy
The same edges and counts as numpy.histogram. Our own tests compare every edge and count with NumPy’s, with each bin rule, on a test signal and on the worked example above. See every check.
Private by design: nothing is uploaded
This tool reads your file and counts the values in your browser, so the file and its name never leave your device. Files with millions of rows work: every value is counted, and the practical limit is your device’s memory.
Next steps with your data
- CSV statisticsMean, standard deviation, min and max of any column.
- Large CSV viewerEach column’s type, and sort, filter and search the rows.
- PSD calculatorHow the power of a vibration is spread over frequency.
- How we check our mathsThe histogram checked against NumPy by our own tests.
- CSV plotterBar, scatter and line charts of the same file.
Frequently asked questions
How do I make a histogram from a CSV file?
Open the file in the tool at the top of this page. Its first number column opens as a histogram straight away. To change the column, untick it in the list on the left and tick another; to change the bins, open Plot settings, then Axes.
How many bins does it use?
By default it picks them for you with NumPy’s “auto” rule: the narrower of the Freedman–Diaconis and Sturges bin widths, which suits both small and large files, at most 500 bins. You can also choose 10, 20, 50, 100 or 200 bins of equal width.
Can I set my own bin edges or a bin width?
Not on the histogram itself: its bins are equal-width, between the smallest and the largest value, by the automatic rule or one of the five counts. On a bar chart, “Summarise” in Plot settings can count the rows in bands of a width you choose instead.
Does it show counts or percentages?
Counts: how many values fall in each bin. The statistics panel gives the total counted, so a bin’s share is its count divided by that total. There is no density or percentage scale yet.
What about Sturges or square-root bins?
The Math dialog’s Histogram (“Bins by a rule” over the plot) gives the bins as a table with the rule you pick: automatic, Freedman–Diaconis, Sturges, square root, or 10, 20, 50 or 100 bins. It is a table of From, To and Count, not a chart.
Is my file uploaded?
No. The file is read and the histogram is calculated by your browser, on your own device. Neither the file nor its name is sent anywhere; you can check it in the Network tab of your browser’s developer tools.
Related tools and guides
- CSV plotterOpen a CSV, Excel, TXT, JSON, MATLAB, Parquet, HDF5 or LabVIEW TDMS file with millions of rows and plot it in several linked charts, with zoom and statistics. Works today.
- Large CSV viewerOpen a CSV with millions of rows in your browser: scroll every row, see each column’s type and statistics, chart any column. Works today.
- MATLAB .mat file viewerOpen v4 to v7.3 .mat files without MATLAB and plot any signal. Works today.
- Parquet viewerOpen large .parquet files, see the schema at once and plot millions of rows, without Python. Works today.
- TDMS viewerOpen .tdms files from LabVIEW, DIAdem and DAQmx loggers: every group, channel and property, each channel plotted against its time. Works today.
- HDF5 viewerOpen .h5, .hdf5 and NetCDF-4 .nc files: every group, dataset and attribute, each group’s datasets plotted against their time. Works today.
- MAT to CSVConvert the signals of a .mat file, v4 to v7.3, to a CSV for Excel or Python, without MATLAB. Works today.
- Parquet to CSVConvert a .parquet file to CSV in your browser, with the columns you pick. Works today.
- TDMS to CSVConvert the channels of a .tdms file to CSV, a group at a time, with its time column, without LabVIEW or Excel add-ins. Works today.
- HDF5 to CSVConvert the datasets of an .h5 or NetCDF-4 file to CSV, a table at a time, with its time column, without Python. Works today.
- Excel to CSVConvert any sheet of an .xlsx or .xlsm workbook to CSV, with the saved results of formulas, real dates and 15 significant digits. Works today.
- JSON to CSVConvert JSON and JSON Lines files to CSV: nested fields become columns named by their path, arrays stay as JSON text. Works today.
- CSV to MATConvert a CSV, Excel, JSON or Parquet file to a MATLAB .mat file: a field per column, with names and units, every row. Works today.
- Merge CSV filesAppend many CSV files into one, even with different columns or separators. Works today.
- Split CSV filesSplit a CSV too big for Excel into parts of 1,000,000 rows, parts of a size you choose, or one file per value of a column. Works today.
- CSV row counterCount the lines in a CSV, TSV or TXT file of any size. Works today.
- CSV statisticsCount, missing values, min, max, mean, standard deviation, RMS and peak to peak of each number column, for the whole file or the rows you zoom into. Works today.
- CSV too large for Excel?Open every row of a CSV beyond Excel’s 1,048,576-row limit, or work around the limit in six other ways.
- FFT and PSD from a CSVTurn a signal column into an FFT spectrum or a PSD with Grms, with results checked against SciPy. Works today.
- PSD calculatorTurn a vibration column into a power spectral density (Welch) in g²/Hz, with the Grms of any band and a dB view. Works today.
- Spectrogram from CSVSee how the frequencies of a measured signal change over time, as a heat map in dB, with the window and range you choose. Works today.
- FRF and coherencePick an input and an output column and get the frequency response (H1, H2, magnitude and phase) and their coherence. Works today.
- The MegaRows toolboxWhat works today and what is coming next, and why nothing is ever uploaded.
Coming soon to MegaRows: CSV to Excel and PDF reports · Compare CSV versions.
MegaRows processes files locally in your browser. Nothing is uploaded, not even the file name.