Create a Power BI Line Chart

Power BI Line Chart is useful for visualizing Trends over time. For example, you can use this to create a Sales trend, Temperate Trend, etc. Let me show you how to create a Line Chart with an example.

For this Power BI Line Chart demonstration, we are going to use the SQL Data Source that we created in our previous article. So, Please refer to Connect to SQL Server article to understand the Power BI Data Source.

How to Create a Line Chart in Power BI

To create a Line Chart, first Drag and Drop the Sales Amount from the Fields section to the Canvas region. It automatically creates a Column Chart.

Bar Graph 1

Next, let me add the State Province Name to the Axis section. You can do this by dragging State Province to the Axis section or checkmark the State Province column.

Bar Graph 2

By clicking the shown icon under the Visualization section, Power BI automatically converts the Column into Line Chart.

From the below screenshot, you can see the Line Chart that shows the Sales Trend by State Province Name.

Create a Power BI Line Chart 3

Create a Line Chart Approach 2

First, click on the Line Chart under the Visualization section, then Power BI will automatically create it with dummy data.

Default Power BI generated Line Chart

In order to add data to the Line Chart, we have to add the required fields:

  • Axis: Please specify the Column Name that represents the Trend.
  • Values: Any Numeric value such as sales amount, Total Sales, etc.

Let me drag the Sales Amount from the Fields section to the Values field and the State Province Name to the Axis section.

Add Sales to Values and State to Axis 5

Let me sort the data by State Province Name (By default, it is sorted by Sales Amount). To do this, click on the … (3 dots) on the top right corner and select the Sort By StateProvinceName option.

Sort by State 6

Now you can see the proper Trend in the Power BI line chart.

Power BI Trend Lines 7

Let me add one more field, i.e., the Total Product Cost to Values section. It will compare the trend of the Sales Amount against the Total Product Cost.

Create a Power BI Line Chart or Trend 8

Hovering over any position shows the Tool-tip of Sales Amount and Total Product Cost.

Tooltip 9

Let me do some quick formatting to this Power BI Line Chart

NOTE: I suggest you refer to the Format article to understand the steps involved in formatting these Lines.

Format Power BI Line Chart or Trends 10


How do you make a line graph in Power BI?

Under the Visualization section, Selecting the Line Chart icon will generate a dummy one. Next, add dates or text fields to X-axis and Numeric measures to Y-axis.

Why line chart is used in Power BI?

Line charts, also known as the trends that visually represent the data changes over a period of time. For instance, sales trends in an interval, profits over the years, etc.

How do you show multiple lines on a Power BI line graph?

There are two ways to show multiple lines. The first one is adding multiple numeric measure values to the Y-axis section. The second approach to adding dimension (text) field to legend.

How do you add a linear line in Power BI?

Use the analytics pane to add the trend lines, constant, min, max, average, median, and percentile lines.