How to Add a Second Line to an Excel Graph
In this article
To add a second line to an Excel graph, you can either select the additional data range before creating the chart or use the "Select Data" menu to add a new series after the chart already exists. Adding a second line allows you to compare two different data sets—such as sales from two different years or temperature readings from two different cities—against the same X-axis (usually time or categories), making trends and correlations immediately visible.
What You'll Need
- Microsoft Excel installed on your computer (Windows or macOS).
- A dataset organized in columns or rows, where one column represents the X-axis (labels) and at least two other columns represent the Y-axis values (the lines).
- An existing line chart, or the raw data ready to be charted.
Step-by-Step
Depending on whether you are starting from scratch or updating an existing graph, choose one of the following methods. Note that menu labels may differ slightly depending on your version of Excel or your operating system.
Method 1: Adding a Second Line During Chart Creation
- Organize Your Data: Ensure your data is in a clean table. For example, Column A should contain your dates or categories, Column B should contain the values for your first line, and Column C should contain the values for your second line.
- Select the Entire Range: Click and drag your mouse to highlight all three columns, including the headers at the top. By selecting all the data at once, Excel automatically recognizes that you want multiple series.
- Insert the Chart: Navigate to the Insert tab on the top ribbon.
- Choose Line Chart: In the Charts group, click on the Insert Line or Area Chart icon. Select the first 2D Line option.
- Verify the Result: Excel will generate a graph with two distinct colored lines, each corresponding to one of your data columns.
Method 2: Adding a Second Line to an Existing Chart
- Select the Chart: Click anywhere inside the chart area to activate the Chart Design and Format tabs in the ribbon.
- Open Select Data: Go to the Chart Design tab and click the Select Data button located in the Data group. This opens the Select Data Source dialog box.
- Add a New Series: In the Legend Entries (Series) box on the left side of the window, click the Add button.
- Define Series Name: A small "Edit Series" window will appear. Click inside the Series name box, then click the cell in your spreadsheet that contains the header for your second line (e.g., "2024 Sales").
- Define Series Values: Delete the default content in the Series values box (which usually says
={1}). While the cursor is still in that box, click and drag to select the actual numerical data cells for your second line. - Confirm the Addition: Click OK on the Edit Series window, and then click OK again on the Select Data Source window. Your second line will now appear on the graph.
Method 3: Using Copy and Paste (The Quick Method)
- Copy the Data: Highlight the column of data you want to add as the second line (including the header) and press Ctrl + C (Windows) or Cmd + C (Mac).
- Paste into Chart: Click once on the chart area to select it, then press Ctrl + V (Windows) or Cmd + V (Mac).
- Adjust Settings: Excel will attempt to automatically add this as a new series. If it adds it as a new category instead, you may need to right-click the chart and use Change Series Chart Type to ensure it is set to a line.
Common Mistakes
One of the most frequent errors is incorrect data alignment. If your first line has 12 data points (e.g., January to December) but your second line only has 10, Excel may struggle to align them correctly on the X-axis, leading to gaps or shifted data points. Always ensure that both data series share the same number of entries and are mapped to the same X-axis labels.
Another common mistake is selecting the X-axis labels twice. When adding a second series via the "Select Data" menu, users often accidentally include the date/category column in the "Series values" box. This causes Excel to plot the dates as a line on the graph, resulting in a line that shoots up to a massive value (because Excel treats dates as large numbers), which flattens your actual data lines at the bottom of the chart.
Users also frequently forget to update the Legend. When adding lines manually, Excel might name them "Series 1" and "Series 2." If you do not explicitly link the series name to a cell header, your audience will not know which line represents which data set, rendering the graph useless for analysis.
Tips
Use a Secondary Axis for Different Scales: If your first line represents a large number (e.g., Total Revenue in millions) and your second line represents a small number (e.g., Conversion Rate as a percentage), the second line will look like a flat line at the bottom of the graph. To fix this, right-click the second line, select Format Data Series, and under Series Options, select Secondary Axis. This adds a second Y-axis to the right side of the chart, allowing both lines to be visible and meaningful.
Distinguish Lines with Markers: If you are printing your graph in black and white, colors won't help. Right-click the line, go to Format Data Series, click the Fill & Line (paint bucket) icon, go to the Marker tab, and choose different marker styles (e.g., circles for line one, squares for line two). You can also change the Dash type to make one line solid and the other dashed.
Dynamic Ranges with Tables: Instead of selecting a fixed range of cells (like A1:B10), convert your data range into an official Excel Table by pressing Ctrl + T. If you build your graph using a Table, any new data you add to the bottom of the table will automatically be added to the lines on your graph without you having to manually update the data range.
Troubleshooting
If the second line doesn't appear: First, check that the data you selected is actually numeric. If the numbers are formatted as text, Excel cannot plot them on a graph. You can tell if numbers are text if they are aligned to the left of the cell by default. Use the Value function or the Text to Columns tool to convert them to numbers.
If the line is a flat horizontal line: This usually indicates a scale issue. Check if the values in your second series are significantly smaller than the first. As mentioned in the Tips section, applying a Secondary Axis usually solves this. If the values are the same scale, check for hidden zeros or empty cells in your data range that might be pulling the line down.
If the X-axis labels change unexpectedly: This happens when Excel misinterprets your data as a series rather than a label. Go back to Select Data. Look at the Horizontal (Category) Axis Labels box on the right. If it says 1, 2, 3... instead of your dates or names, click Edit and re-select the range containing your X-axis labels.
If the chart becomes cluttered: When adding multiple lines, the graph can become "spaghetti-like." To fix this, try removing the gridlines (click a gridline and press Delete) or moving the legend to the bottom of the chart to provide more horizontal space for the data lines.
Frequently Asked Questions
Can I add a third or fourth line using the same method?
Yes. The process for adding a second line is identical for any subsequent lines. You can continue to use the "Add" button in the Select Data menu or copy-paste additional columns into the chart.
How do I change the color of the second line?
Right-click directly on the second line in the graph to open the Format Data Series pane. Click the Fill & Line (paint bucket) icon and select a new color from the Color dropdown menu.
Why does my second line look like a series of dots instead of a line?
This happens if your chart type is set to "Line with Markers" but there is missing data between points. Ensure there are no empty cells in your data range, or go to Select Data > Hidden and Empty Cells and choose Connect data points with line.
Can I mix a bar chart and a line chart?
Yes. This is called a Combo Chart. Right-click the second line, select Change Series Chart Type, and in the Combo category, you can set one series to Clustered Column and the other to Line.
How do I remove the second line if I no longer need it?
The fastest way is to click on the line itself in the chart to select it, then press the Delete key on your keyboard. Alternatively, go to Select Data and remove the series from the list.
What happens if my second line has a different time scale?
Excel line charts generally assume a shared X-axis. If your second line uses different dates, you should use an XY Scatter Plot instead of a Line Chart. Scatter plots treat the X-axis as a value scale rather than a category list, allowing points to be placed precisely regardless of the other series.