Field Guide

Sparklines in Excel: insert Line, Column, and Win/Loss in-cell charts

Updated

To add a sparkline in Excel, select a blank cell next to your data, then on the Insert tab, in the Sparklines group, choose Line, Column, or Win/Loss. In the Create Sparklines dialog, enter the Data Range that holds the numbers, for example B2:E2, confirm the Location Range is the cell you selected, and select OK. Excel draws a tiny chart inside that one cell that reads the row of values.

A sparkline is a mini chart in the background of a single cell, so it summarizes a run of numbers right where you can see them, without building a full chart object. The cell keeps no value of its own from the sparkline, which is the first thing to get straight about them, and the choice between Line, Column, and Win/Loss decides what the little chart actually tells you.

How do I insert a sparkline?

Pick the cell where the chart should sit first, usually the blank cell at the end of the row it summarizes, since a sparkline reads best next to its data. Then on the Insert tab, in the Sparklines group, choose the type you want, and fill in the Create Sparklines dialog: the Data Range is the block of numbers to chart, and the Location Range is the cell (or cells) that will hold the sparklines. If your figures are in cells B through E of row 2, the Data Range is B2:E2. Select OK and the chart appears.

A B C D E F
1 Region Q1 Q2 Q3 Q4 Trend
2 East 120 90 140 110
The Data Range is B2:E2, the four quarter figures shaded amber. The sparkline is drawn in the Location cell F2, marked green. F2 holds no number of its own, so a Line chart traces the quarters inside that one cell and you can still type a label over the top.

To repeat a sparkline down a table, select the one you made and drag its fill handle, or use Fill Down (Ctrl+D), the same way you copy a formula. When the numbers in the Data Range change, the sparkline redraws on its own to match, because it is a live picture of that range rather than a snapshot.

The Microsoft page that documents this route, “Analyze trends in data using sparklines,” lists Excel for Microsoft 365, 2024, 2021, 2019, and 2016; on a Mac the dialog is named Insert Sparklines but the Data-Range-then-location flow is the same.

What is the difference between Line, Column, and Win/Loss?

The three types read the same numbers but draw them differently, and mixing up the last two is the usual mistake.

That last contrast is the one to hold onto. Feed the row 9, then -2, then 14, then -1 to a Column sparkline and you get a tall bar, a short bar below the line, a taller bar, and a small one below, all sized to the numbers. Feed the same row to a Win/Loss sparkline and you get up, down, up, down, every marker identical, because 9 and 14 are both just positive. Column answers how much; Win/Loss answers only which way.

For the cell-filling cousin of these in-cell visuals, conditional formatting adds data bars and color scales, which shade or fill the cell itself based on its value rather than charting a range of neighboring cells.

Is a sparkline a value in the cell?

No, and this is what sets a sparkline apart from a formula result. The chart is painted in the background of the cell, so the cell carries no value from it. You can click into that cell and type text, and the text sits on top of the sparkline as a label, which is why people drop a region name or a total right over the chart. Because the sparkline is not a value, no formula can read it, and the ordinary Delete-key route for clearing a cell does not remove it. Removing one has its own command, below.

How do I format or change a sparkline?

Select a sparkline and Excel shows the contextual Sparkline tab (named Sparkline Design on a Mac). Everything you change there applies to the sparkline you selected, and to the rest of its group with it. From that tab you can:

Sparklines you create together in one action form a group, and formatting them is an all-at-once affair: a change on the Sparkline tab lands on every sparkline in the group. When you want to style or retype just one, choose Ungroup first to break the set apart, then work on the single chart on its own.

How do I remove a sparkline?

Select the cell and choose Clear on the Sparkline tab; the arrow beside Clear lets you clear the one sparkline or the entire group. Pressing the Delete key does not take it off, because the chart lives in the cell background rather than as the cell’s value. Delete clears any label text you typed over the sparkline and leaves the chart in place, which is a common source of confusion, so reach for Clear instead.

One more setting to check before you rely on a sparkline: by default it leaves out data sitting in hidden rows or columns. If you have filtered or hidden part of the source and want it counted anyway, select the sparkline, open the Hidden and Empty Cells dialog from the Sparkline tab, and turn on Show data in hidden rows and columns. The same dialog decides how empty cells read, as Gaps, as Zero, or connected across with a line.

The short version

Frequently asked questions

How do I insert a sparkline in Excel?
Select a blank cell near the row of numbers you want to chart, usually at the end of the row. On the Insert tab, in the Sparklines group, choose Line, Column, or Win/Loss. In the Create Sparklines dialog, enter the Data Range that holds the numbers, for example B2:E2, check that the Location Range is the cell you selected, and select OK. Excel draws the mini chart inside that one cell. On a Mac the dialog is named Insert Sparklines and the steps are the same.
What is the difference between Line, Column, and Win/Loss sparklines?
A Line sparkline connects the values into a small line, so you read the shape of the trend. A Column sparkline draws a bar for each value sized to its magnitude, so a bigger number gets a taller bar. A Win/Loss sparkline is the one people misread: it shows every value as an equal-size marker by its sign only, pointing up for a positive value and down for a negative value, with a gap for zero, and it ignores magnitude entirely. So in Win/Loss a value of 8 and a value of 120 look identical, because both are simply positive.
Is a sparkline a value in the cell?
No. A sparkline is a tiny chart drawn in the background of a single cell, not the cell's contents, so the cell has no value of its own from the sparkline. You can still type text into that cell and it sits on top of the chart, which is handy for a label. Because the chart is not a value, a formula cannot read it, and it is not removed by pressing the Delete key.
How do I remove a sparkline in Excel?
Select the cell that holds the sparkline, then on the Sparkline tab choose Clear (use the arrow beside Clear to clear one sparkline or the whole group). Pressing the Delete key does not take the sparkline off, because the chart lives in the cell background rather than as the cell's value; Delete clears any text you typed over it, not the chart. On a Mac the same command is on the Sparkline Design tab.
How do I show high and low points on a sparkline?
Select the sparkline, then on the Sparkline tab, in the Show group, check the markers you want, such as High Point and Low Point, First Point and Last Point, or Negative Points. For a Line sparkline you can also check Markers to dot every value. Use Marker Color to recolor them. These options highlight individual values without changing the underlying data.
Do sparklines include hidden or empty cells?
By default a sparkline leaves out data that sits in hidden rows or columns. To change that, select the sparkline, open the Hidden and Empty Cells dialog from the Sparkline tab, and turn on Show data in hidden rows and columns. The same dialog controls empty cells, which you can show as Gaps, as Zero, or by connecting the points with a line.

Catch the errors before they ship

Reviewing a change to a model? Compare the two versions in your browser and see every changed cell, formula, and value. It's free, and nothing leaves your computer.