How to Make a Line Graph in Excel – Easy Tutorial
Line graphs are a highly valuable tool in Excel, helping users analyze trends and patterns effectively over time. They are widely used for time-series analysis in Excel, allowing a clear visual representation of changes in data. In this guide, you’ll learn how to create a line graph in Excel, including steps to build single or multiple line graphs, explore different Excel chart types, and customize line charts to suit your needs. Whether you’re preparing a presentation or conducting in-depth analysis, this Excel line chart tutorial will help you turn raw data into insightful visuals.
Disclaimer: Ensure your data is accurate and well-organized to achieve precise and reliable visualizations.

How to Create a Line Chart in Excel
What is a Line Chart in Excel
A line chart also known as a line graph, is a visual representation that shows a series of data points connected by a straight line. In a line chart, the independent values such as time intervals or categories, are plotted on the horizontal x-axis, while the dependent values, like prices or sales, are plotted on the vertical y-axis. Values that are represented below the x-axis are the negative values. Line graphs are widely used in various fields to track trends and patterns in data over time.
How to Create a Line Chart in Excel
If you’re wondering how to generate a line graph in Excel, follow these simple steps. You can also customize line charts for better visualization:
Step 1: Prepare Your Data
In this step, we will be inserting random sales data for three different courses for the last five years in our Excel sheet. Below is the screenshot of the random sales data that we are going to use for our line chart.

Prepare Your Data
Step 2: Insert the Line Chart
- Highlight the Data
- Go to the Insert tab on the Excel ribbon.
- In the Charts group, click on the Insert Line or Area Chart dropdown.
- Choose the 2-D Line Chart option.
Excel will now create a Line Chart that plots:
- Years on the X-axis.
- DSA, Java, and AI/ML as separate lines on the Y-axis.
Once we select our desired line chart (Here, Line with Markers). Excel will automatically plot a graph for our dataset.

Select Data>> Go to Insert Tab >>Select the 2-D Line >> Chart
In the above graph, we can easily visualize the different courses that are sold. In the next step, we will try to format our graph.
Step 3: Customize and Format the Line Chart
We will try to format our graph according to our needs in this step.
Add Chart Title
- Click on the default Chart Title at the top of the chart.
- Type a meaningful title like “Line Chart – Courses Sales“

Change the Graph Title
Add Axis Titles
- Click on the chart to activate the Chart Elements button (the “+” icon on the chart).
- Check the Axis Titles box.
Add titles:
- Horizontal Axis: “Year”
- Vertical Axis: “Number of Students (or Values)”

Click on the “Plus” icon
Format Lines and Markers
- Click on any line in the chart (e.g., the DSA line).
- Right-click and select Format Data Series.
- Customize the line color, width, and marker style:
- Example: Use a solid line with circles as markers for better visibility.
- Repeat this for the other lines (Java and AI/ML).

Format Lines and Markers
Add Data Labels
- Right-click on one of the lines in the chart.
- Select Add Data Labels.
- The values will appear at each point on the line.
- Customize the data label position if needed.
Customize the Legend
- Click on the legend (showing DSA, Java, AI/ML) to select it.
- Move the legend to your preferred location (e.g., top, bottom, or right of the chart).

Add Data Labels and Customize the Legend
Step 4: Finalize the Chart
- Resize the Chart: Click and drag the edges to resize the chart as needed.
- Format the Gridlines: Right-click on the gridlines and choose Format Gridlines to adjust their style or remove them.
- Save the Workbook: Press Ctrl + S to save the Excel file with the chart.
How to Make a Multiple Line Graph in Excel
A Multiple Line Graph (also called a multi-line chart) allows you to compare trends or changes across multiple datasets over time or categories. Here’s a step-by-step guide to create one in Excel:
Step 1: Organize Your Data
Prepare your data in a table format where:
- The first column contains categories (e.g., years, months, or labels).
- The following columns contain values for each dataset.
Year | Series 1 | Series 2 | Series 3 |
---|---|---|---|
2017 | 30 | 15 | 5 |
2018 | 50 | 60 | 10 |
2019 | 67 | 35 | 25 |
2020 | 40 | 65 | 30 |
2021 | 85 | 80 | 25 |
2022 | 100 | 90 | 40 |
Step 2: Select Your Data
- Highlight the entire data range, including headers (e.g., A1:B7).
- This will create a Single series Line Chart in Excel
Step 3: Insert the Single Line Graph
- Go to the Insert tab on the Excel ribbon.
- In the Charts group, click the Insert Line or Area Chart dropdown.
- Choose Line Chart (2-D Line).

Select the Data>> Go to Insert Tab >> Select the 2-D Chart
Step 4: Add Another Data Series
- Right-click on the chart and select “Select Data“.
- In the Select Data Source window, click “Add” to add a new data series.
- For the Series Name, click on the header in cell C2 (e.g., “Sales“).
- For the Series Values, select the data range C3:C14.
- Click OK to confirm.
- Click OK again to close the Select Data Source window.

Right Click >> Choose “Select Data”>>Click on “Add”>> Add “Series Name” and “Series Value”>>Click ok
Note: Similarly you can add multiple lines.
Step 5: Customize and Format the Line Chart
1: Add Chart Title and Axis Titles
- Click on the Chart Title and type a meaningful title, such as “Trends Over Time”.
To add axis titles:
- Click the chart.
- Use the Chart Elements button (+) and check Axis Titles.
- Rename the X-axis as “Years” and the Y-axis as “Values“.

Click on the Add Button >>Check the “Axis Titles” and ” Chart Title” Checkbox >> Add the Chart Title and Axis Title
2: Format the Lines
- Click on any line to select it.
- Right-click and choose Format Data Series.
Customize:
- Line Color: Choose a unique color for each series.
- Line Style: Adjust line thickness or make it dashed.
- Markers: Add data markers to highlight points on each line.

Right Click >> Select “Format Data Series”” >> Customize
3: Add a Legend
Excel automatically adds a legend (e.g., Series 1, Series 2, etc.). To customize it:
- Click on the legend.
- Move it to the desired position (top, bottom, right, or left).
4: Add Data Labels (Optional)
- Right-click on a line and select Add Data Labels.
- Adjust label positions for better clarity.

Right Click >> Select ” Add Data Labels”>> Preview Results
Step 6: Compare Multiple Lines
Once your chart is created, you can easily see:
- How each dataset changes over time (trends).
- Differences or similarities between multiple lines.
- Peaks, dips, or intersections between datasets.
Step 7: Save and Update the Graph
- Save your Excel workbook.
- If your data changes, the chart will automatically update.

Preview the Multiple Lines Chart
Different Types of Line Charts in Excel
When creating line graphs, there are several Excel chart types to choose from depending on your data and analysis needs:
1. Stacked Line
It aims to demonstrate how different elements of a whole alter over time. The top line in this graph represents the sum of all the lines below it because the lines in this graph are cumulative, which means that each new data series is added to the first.

Stacked Line
2. 100% Stacked Line
It resembles a stacked line graph, but the y-axis displays percentages rather than absolute numbers. The top line, which spans the top of the chart directly, indicates a sum of 100% at all times. This kind is usually used to illustrate the gradual contribution of a part to the whole.

100% Stacked Line
3. Line with Markers
The line graph with markers at each data point in the marked form. Stacked Line and 100% Stacked Line graphs are also available in marked forms. Use this chart type when there are few data points.

Line with Markers
4. 100% Stacked Line with Markers
Use this chart type to show the percentage contribution to a whole over time or categories. Show the change to the percentage that each value contributes over time.

Stacked Line with Markers
5. 3-D Line
An alternative to the traditional line graph in three dimensions.

3-D Line
Advanced Tips for Line Graphs in Excel
When you make a line graph in Excel, these advanced tips can help you improve your chart:
1. Adding a Secondary Axis
- Use a secondary axis to display two datasets with different scales on the same chart.
- For example, plot sales numbers on the primary axis and profit percentages on the secondary axis for better comparison.
- In Excel, right-click on a data series, choose Format Data Series, and select Secondary Axis.
2. Using Combo Charts (Line + Bar)
- Combine line graphs with bar charts to show trends alongside categorical data.
- For example, use a bar chart to show revenue by product and overlay a line graph for profit trends.
- Select Insert Combo Chart in Excel and customize the chart for a dynamic presentation.
3. Handling Large Datasets with Filters
- Apply filters to focus on specific subsets of data in large datasets.
- For example, filter by date range, region, or category to analyze specific trends without overcrowding the chart.
- In Excel, use slicers or the filter dropdown to display only the relevant data points.
These tips help you enhance line graphs for complex datasets and more effective visual storytelling.
Also Read:
Conclusion
Creating a line graph in Excel is an essential skill for presenting data trends and patterns effectively. With the steps outlined in this guide, you can easily make a line graph in Excel, customize it, and even compare multiple datasets for a deeper understanding of your data. Use these tools to elevate your analysis and create compelling visuals that communicate your insights clearly and professionally.
FAQs about Line Graphs in Excel
How to handle missing data in a line graph?
- Ignore Missing Data: Most tools automatically skip blank cells, leaving gaps in the line graph.
- Interpolate Missing Data: Use linear interpolation to estimate missing values and create a smoother line. For example, in Excel, select Select Data > Hidden and Empty Cells > Connect Data Points with a Line.
- Fill with Averages: Replace missing data with the average of adjacent values if it’s suitable for your dataset.
Best practices for formatting line charts
- Use Clear Labels: Add meaningful axis titles and a descriptive chart title for better understanding.
- Choose Contrasting Colors: Use distinct colors for multiple lines to differentiate data series.
- Add Data Markers: Highlight specific data points with markers to make trends more visible.
- Limit Gridlines: Reduce gridlines to declutter the chart and improve readability.
Troubleshooting issues like overlapping labels or uneven scales.
- Overlapping Labels: Adjust the label position or use abbreviations to prevent labels from overlapping.
- Uneven Scales: Ensure both axes have appropriate and consistent scales to avoid distortion. Use a secondary axis if needed.
- Cluttered Data Series: Reduce the number of series or split data into multiple charts for clarity.
These strategies help you handle missing data, format line graphs effectively, and resolve common issues.
How do I create a Line chart in Excel?
Follow the below steps to create a line chart in Excel:
- Prepare your data.
- Select the dataset you want to use for the line chart.
- Go to the “Insert” tab on the Excel ribbon.
- Click on the “line” chart icon in the “Charts” group.
- Choose the line chart type that best fits your need.
How to make line graph in excel with 2 variables?
Follow the steps given below:
- Prepare Your Data
- Select Data
- Go to the Insert tab
- Insert Line Chart
- Choose the desired line chart style
How to create line graph in excel with x and y axis?
Here are some steps to create line graph in Excel:
- Prepare Your Data
- Select Data
- Go to the Insert tab
- Insert Scatter Plot
- Select the Scatter with Straight Lines
How to make line graph in excel with 3 variables?
Steps to make a line graph in Excel:
- Select Data
- Insert Line Chart
- Go to the Insert tab.
- In the Charts group, click on the Line chart icon.
- Choose the Line with Markers
How do I make a line up chart in Excel?
Follow the steps given below:
- Select Data
- Insert Line Chart
- Go to the Insert tab
- In the Charts group, click on the Line chart icon.
- Select the desired line chart