You create a line plot by putting your ordered x-values in one column and your y-values in the next, selecting both columns, and inserting a line chart that connects consecutive points in the order your rows appear. The whole job takes under two minutes in Excel and about ten lines of code in Python. Two conditions decide whether the result is honest: your x-axis must be ordered (dates, time, or a numeric scale), and you must know whether points should be connected or only marked. Get those two right and almost nothing else can go wrong.
Decide Whether Your Data Belongs in a Line Plot at All
A line plot earns its place when the horizontal axis carries a continuous or ordered quantity and the vertical axis carries a measurement taken at each of those positions. Monthly sales, daily temperature, voltage over a sweep, dose response, and download counts by week all fit. The connecting line encodes an assumption β that a value exists between your recorded points β and that assumption is only reasonable when the axis is ordered.
Categorical data does not belong here. If your x-values are product names, countries, or departments, a bar chart communicates the same numbers without implying a progression. Excel will still draw a line through categories, which is exactly why the wrong-chart mistake is so common. Ask one question: could a value plausibly exist between my first and second x-points? If yes, a line fits.
Watch for time gaps. Weekly readings that skip three weeks produce a straight line across the gap, which reads as steady stability when you actually have no data. Google's chart guidance treats gaps as a distinct problem from zeros, and the distinction matters: a missing measurement and a measured zero both plot at the bottom if you fill blanks with zero, but only one of them is true. Leave gaps empty or break the series into segments.
Duplicate x-values also break the premise. Two readings at the same timestamp cannot both sit on a single-valued function, so aggregate them first β average, sum, or take the last reading β and state which rule you used. A reader who cannot tell whether you averaged or summed has no way to check your plot.
Number Your Steps: Clean the Data Before You Draw Anything
Data cleaning takes longer than the chart itself, and skipping it is the most reliable way to produce a line plot nobody can trust. Work through these steps in order on a copy of the sheet, never the original.
1: Open the raw file and duplicate the sheet. Right-click the sheet tab, choose Move or Copy, tick Create a copy. Every later edit stays reversible. 2: Sort ascending by the x-column. Select the full data range, then Data > Sort, choose your date or time column, and set Order to Oldest to Newest. Unsorted rows are the single most common cause of a zigzag line. 3: Convert text dates to real dates. Select the column and use Data > Text to Columns > Finish. Look for left-aligned values, which signal text; real dates right-align by default in Excel. 4: Standardize units in the y-column. Filter for entries containing "k", "mm", or "%" pasted in from another system and replace them with numeric values in a consistent unit. 5: Handle blanks deliberately. Use Find & Select > Go To Special > Blanks to see how many exist. Leave them empty for a gap, or enter 0 only if a zero was actually measured. 6: Check for outliers with a quick scan. Sort the y-column descending and inspect the top five values for typos such as a decimal point shifted one place. 7: Name the range. Select the cleaned two columns and type a name in the Name Box, for example PlotData. Named ranges survive row insertions that break hard-coded chart references.
Failures cluster in step three. Excel's automatic date detection fails on formats like 20260315 or on dates copied from systems set to day-first conventions, and the resulting chart plots every point at the same x-position. If your line is vertical, the x-column is text.
A second failure hides in step five. Filling blanks with zero flattens a genuine gap into a measured trough, and audiences read troughs as events. If you cannot tell whether a blank means zero or unknown, treat it as unknown and say so in the caption.
Build the Chart in Excel: Exact Ribbons and Default Settings
Excel remains the default tool for this job, and the Insert tab path is short. The defaults, though, are not all what most people want, so plan to adjust two settings immediately after insertion.
| Action | Exact path in Excel for Microsoft 365 | Default you get | What to change |
|---|---|---|---|
| Insert the chart | Select both columns > Insert > Charts group > Insert Line or Area Chart > Line | Line with markers off, legend on | Add markers if you have fewer than 30 points |
| Plot a date axis | Right-click chart > Select Data > Horizontal (Category) Axis > Edit | Automatic axis type | Choose Date axis to respect real intervals |
| Show a gap for blanks | Right-click chart > Select Data > Hidden and Empty Cells | Gaps shown as gaps; zeros plotted if blanks were filled with 0 | Select Connect data points with line only if gaps are short and expected |
| Add axis titles | Chart Design > Add Chart Element > Axis Titles | No titles | Both axes, with units in the y-title |
| Format the y-axis range | Right-click the y-axis > Format Axis > Bounds | Auto minimum, often not zero | Set a manual minimum and document it |
The first decision after insertion is whether to show markers. With twelve monthly points, markers help readers locate the actual measurements. With 500 daily points, markers blur into a solid band and lines alone read better. There is no universal rule, but the threshold most analysts use sits somewhere around 30 points.
The second decision is the y-axis minimum. Excel's automatic minimum will happily start a sales chart at 4,800 when values range from 4,800 to 5,200, magnifying a 4% move into a dramatic climb. That is sometimes what you want and sometimes misleading. If you set a non-zero minimum, put it in the axis title or a note so the reader sees the truncation.
Date-axis versus category-axis is the setting that quietly changes the truth. On a category axis, readings taken 1 day apart and readings taken 30 days apart occupy equal horizontal space. Switch to a date axis and the spacing becomes proportional, which is what most audiences assume they are seeing. Check this on every chart with irregular intervals.
One more default deserves attention: Excel drops the legend when there is only one series, which is fine, but it also titles the chart "Chart Title" until you click it. Replace that text with a sentence stating what the line shows, not with the column header alone.
Draw the Same Plot in Python With Matplotlib and pandas
Python suits line plots you need to regenerate, parameterize, or produce in batches. Matplotlib is the standard plotting library, and pandas wraps it with a one-line convenience method. The full sequence fits in about ten lines.
The parse_dates argument in read_csv is the Python equivalent of Excel's text-to-date problem: skip it and pandas stores your dates as strings, producing a category axis with evenly spaced labels. The sort_values call after loading matters for the same reason sorting matters in Excel β Matplotlib draws points in row order and will happily connect them out of sequence.
Frequency handling in pandas rewards a specific path. Use df.resample("W").mean() to convert daily readings to weekly averages, and be aware that the default closed and label arguments on resample place each weekly bin at either its start or end β the default is right-closed and right-labeled for most frequencies. If your weekly labels look shifted by a week, that argument is why.
Two failure modes dominate. Matplotlib's plot on a pandas Series with a DatetimeIndex will often produce the date axis automatically, but calling it on two plain columns without datetime conversion gives the string-axis problem silently. Separately, plt.plot with a marker argument on thousands of points slows rendering and produces an unreadable band; drop markers above roughly 200 points.
For dates, pandas and Matplotlib agree on parsing ISO 8601 order, but ambiguity creeps in with values like 03/04/2026. Pass dayfirst=True or format="%d/%m/%Y" explicitly rather than trusting the parser. Silent misparsing produces a plot that looks fine and is wrong by months, which is the worst kind of error because it survives every visual check.
Match the Chart Type to the Story You Need to Tell
The plain line is one of several related charts, and picking the wrong variant misleads in specific, predictable ways. Compare the four common options on the same dimensions before you commit.
| Variant | Encodes | Use when | Known drawback |
|---|---|---|---|
| Simple line | One series over an ordered axis | Single metric, clear trend | Hides count of underlying observations |
| Multi-line with legend | Two to five series | Comparisons on the same scale | Colors beyond five become indistinguishable |
| Stacked area | Cumulative total and composition | Parts of a whole over time | Only the bottom series has a true baseline |
| Line with error bars or bands | Uncertainty around each point | Confidence intervals or standard deviation | Bands overlap and turn muddy with three series |
The stacked-area chart deserves a specific warning. Because every series except the bottom one is offset from zero by the series below it, its slope reflects both its own change and the change in everything beneath it. A flat middle series sitting on a rising bottom series will appear to rise. If you need composition over time, a small multiple of plain lines usually communicates more honestly than a stack.
Multi-line charts hit a practical limit around five series. Color-blind-safe palettes and direct labeling β placing the series name at the end of each line instead of in a legend β push that limit a little further, but beyond six lines most readers give up. If your data has twelve countries, plot the top five and roll the rest into an "Others" line, or facet into three small charts.
Error bands suit experimental data. A mean with a 95% confidence interval over time tells a different and more honest story than the mean alone. The cost is visual density, so reserve bands for cases where overlap between series genuinely matters to the conclusion. A single band on one line is usually cleaner than bands on three.
Combination charts β a line overlaid on bars β solve the "two different quantities over time" problem, but only if you put each series on a clearly labeled secondary axis and mention the dual axes in the caption. A reader unaware of a secondary axis will compare line height to bar height and draw a false conclusion.
Scale and Interval Choices That Change the Message
Axis scaling is where two honest analysts can produce opposite impressions from the same numbers. The choices are defensible in both directions, but only one of them is defensible in each specific case, and the caption should say which you chose.
A y-axis starting at zero is required when the chart shows magnitude or compares bar heights, and it is optional when the chart shows rate of change. The problem is that zero-based axes hide small but meaningful movements. If your conversion rate moves from 3.1% to 3.4%, a zero-based axis renders the change invisible. The standard resolution is a truncated axis with an explicit break marker or a clear note in the title.
Axis breaks drawn with two parallel slashes tell the reader that range has been removed. Without that marker, a truncated axis reproduces exactly the journalistic distortion that motivates complaints about misleading charts. If your plotting tool cannot add a break cleanly, state the minimum in the axis label, as in "Revenue in β¬m (axis starts at 40)".
Log scales are the correct answer when your data spans orders of magnitude, such as growth from 100 to 100 million users. On a linear scale the early years flatten into one horizontal line and every story about early momentum disappears. A log-scale y-axis equalizes relative changes, so a doubling appears the same everywhere on the chart. Label the axis "log scale" and consider showing a linear version alongside it.
Time intervals deserve the same scrutiny. Daily data plotted over a year produces 365 noise-heavy points where a 7-day rolling average reveals the trend. Weekly aggregation smooths weekends without erasing seasonality. The publication rule of thumb: aggregate at the coarsest interval that still preserves the pattern you are pointing to, and state the interval in the subtitle.
Mixing intervals inside one chart is the trap. A series of monthly totals alongside a series of daily averages cannot share a y-axis meaningfully. Convert both to the same interval before plotting, and note the conversion.
Add Readers: Titles, Axis Labels, Annotations, and a Data Source
A line plot without labels is a puzzle, not a chart. The minimum readable set is four elements: an action title, axis titles with units, a data source line, and annotations for anything unexpected. Each takes seconds and each removes a specific reader question.
The title should state the finding, not the contents. "Weekly active users grew 34% between January and June 2026" beats "Weekly Active Users Over Time," because the reader gets the conclusion before studying the axis. Keep the contents in the subtitle if you need it, along with the aggregation interval.
Axis titles need units and, when relevant, the aggregation. "Revenue (β¬ thousands, weekly totals)" is complete; "Revenue" is not, because a reader cannot tell whether a point is a day, a week, or a quarter. On date axes, add the time zone or reporting cutoff if the data crosses midnight anywhere.
Annotations carry the highest information density per pixel. Mark a launch date with a vertical line and a short label, mark a system outage with a shaded band, and mark the latest value with a direct label. Direct labels at the end of each series reduce legend-hunting and let you delete the legend entirely for a single-series chart.
The data source line is non-negotiable for anything published. Name the system, the date the data was extracted, and the row count. "Source: internal billing exports, pulled 3 November 2026, 168 weekly records" lets a skeptical reader reconstruct the whole thing. Without it, the plot is an assertion.
One accessibility note: roughly 8% of men experience some form of color vision deficiency, so a two-line chart in red and green is a real problem. Use a color-blind-safe palette, vary the line style as well as the color, and keep markers distinct in shape.
Fix the Five Failures That Ruin Most Line Plots
Most broken line plots fail in five recognizable ways, and each has a specific repair. Recognizing them by symptom shortens debugging considerably.
The vertical line or clumped points mean a text x-axis. Repair: convert dates to real date values, then rebuild the chart. The tell is left-aligned text in the column.
The zigzag that jumps back and forth means unsorted rows. Repair: sort ascending by x, then refresh the chart data. This is the most common and easiest fault.
The flat line across a gap means blank cells were filled with zero or the chart's empty-cell setting was changed to interpolate. Repair: restore the blanks and set the chart to show empty cells as gaps.
The line that ends before the axis does means the chart's source range stops short of the last row. Repair: re-select the full range, or better, point the chart at a named range or an Excel Table, which expands automatically when rows are added.
The truncated y-axis that magnifies a trivial change means the auto minimum sits far above zero without explanation. Repair: either reset the minimum to zero or annotate the truncation.
A sixth failure appears in shared files: the chart references a specific sheet name that someone renames, and every value reads as #REF!. Pointing at named ranges prevents this, which is the same reason naming the range appeared in the cleaning steps.
When a Line Is the Wrong Choice, and How to Tell
Knowing when not to use a line plot prevents the most embarrassing chart mistakes, and the rules are concrete enough to check in seconds.
Use a bar chart when the x-values are categories with no inherent order. A line between "France" and "Germany" implies a continuum that does not exist. Use a scatter plot when both axes are measurements and you want to show correlation without order assumptions. Use a histogram when the interesting pattern is the distribution of one variable, not its evolution. Use a dot plot or lollipop chart when you have a handful of comparisons and want to emphasize the individual values.
Cyclical data has a specific alternative. Sales by month across a single year read naturally as a line if you want the within-year shape, but if you want to compare months across years, use a small-multiple grid of 12 mini-charts or a seasonal heatmap. A 10-year monthly line plot with 120 points produces a spiky mess where the annual pattern disappears.
Step data is another case. Values that hold constant between changes β inventory levels, pricing tiers, account balances β are more honest with a step line, which draws a horizontal segment followed by a vertical jump. A standard line draws a diagonal slope that never existed. Excel offers a stacked area chart rather than a true step chart, but Python's Matplotlib supports drawstyle="steps-post" directly.
Extremely sparse data β five points over five years β belongs in a dot plot with a connecting line drawn only if the connection is the point. Otherwise the reader spends attention on the line rather than the five measurements, which are the entire dataset.
FAQ
How many data points do I need before a line plot stops looking noisy?
Around 30 to 50 points is where a plain line starts to read as a trend rather than a sequence of events. Below 12 points, markers help readers see that they are looking at individual measurements. Above 200 points, drop the markers and consider a rolling average, provided you state the window length in the subtitle.
Why does my Excel line chart show every point at the same horizontal position?
Your x-column is text, not dates or numbers, so Excel treats each entry as a separate category. Select the column and run Data > Text to Columns with the Finish button. Left-aligned entries are the usual visual tell, since real dates and numbers right-align by default.
Can I put two different units on the same line chart?
Yes, by assigning the second series to a secondary axis, but you must label that axis and mention the dual scale in the caption. Without the note, readers compare the heights of the two lines and draw a conclusion that depends entirely on arbitrary axis scaling. If both series do not need to appear on one chart, two separate charts is safer.
Is a line plot allowed to have a y-axis that starts at something other than zero?
Yes, when the chart's purpose is to show rate of change rather than magnitude. State the truncation in the axis title, for example "Axis starts at 40," or add a break marker. A truncated axis without any note is the specific pattern most often flagged as misleading in chart-criticism guides.
What is the difference between a line chart and a time-series chart?
A time-series chart is a line plot whose x-axis is time; the terms overlap. The practical difference is the axis type: a true time series uses proportional spacing between dates, so a 30-day gap looks 30 times wider than a 1-day gap. Category axes in Excel space every point equally regardless of date, which hides irregular sampling.
How do I handle weekends and holidays that have no data?
Leave them blank rather than entering zero. A zero on a non-working day depresses the line and suggests a real drop in activity. Excel shows blank cells as gaps by default; if you filled them with zeros earlier, clear those cells and let the chart show the gap.
Does Matplotlib plot points in the order of my DataFrame rows?
Yes, and that is why an unsorted DataFrame produces a zigzag. Matplotlib connects points in the order they are passed, so df.sort_values("date") before calling plot is essential. Unlike Excel, Matplotlib offers no later "sort" toggle, so the fix belongs in the data preparation step.
What is the quickest way to check whether my finished line plot is honest?
Cover the title and ask what change the line appears to show, then look at the numbers behind it. If the visual impression differs from the arithmetic change, one of three settings is responsible: the y-axis minimum, the axis type, or the aggregation interval. The chart is honest when the impression matches the arithmetic and the caption states which of those three settings you chose.