How to Make a Line Graph in Looker

Cody Schneider9 min read

A line graph is one of the most effective ways to visualize trends, patterns, and fluctuations in your data over time. Whether you’re tracking website sessions, daily sales, or campaign performance, plotting your metrics on a line graph turns rows of numbers into a clear, compelling story. This tutorial will walk you through exactly how to build, customize, and read a line graph step-by-step in Looker (now part of the Looker Studio family).

GraphedGraphed

Build AI Agents for Marketing

Build virtual employees that run your go to market. Connect your data sources, deploy autonomous agents, and grow your company.

Watch Graphed demo video

When Is a Line Graph the Right Choice?

Before jumping into the builder, it’s important to know when a line graph is actually the best choice for your data. Line graphs excel in one particular area: showing a continuous trend for a numerical value over a specific time interval.

Think of it this way: if you can frame your question as "How did [metric X] change over [time period Y]?", a line graph is likely your best bet. Here are a few common scenarios where a line graph is the perfect fit:

  • Website Analytics: Tracking daily new users, weekly pageviews, or monthly bounce rates.
  • Sales Performance: Visualizing monthly recurring revenue (MRR), quarterly sales totals, or revenue by product over the year.
  • Marketing Campaigns: Monitoring daily ad spend vs. conversions, weekly email open rates, or social media follower growth over a campaign lifecycle.
  • Operational Metrics: Charting the number of support tickets created per day or average response time per week.

The key connecting all these examples is the element of time. While a bar chart is great for comparing distinct categories (like total sales per country), a line graph is superior for showing the flow and progression of data over a continuous period.

Before You Build: Understanding Key Looker Concepts

The Looker interface can feel a bit intimidating at first, but it's built on two core concepts you need to grasp: Dimensions and Measures. Understanding these will make building any chart, not just a line graph, much easier.

  • Dimensions: These are the "what" or "when" attributes in your data. Think of them as the categories you use to group your numbers. In the context of a line graph, your primary dimension will almost always be time-based, like Date, Week, or Month. Other non-time dimensions include things like Country, Traffic Source, or Product Name.
  • Measures: These are the "how much" or "how many" parts of your data. They are always a numerical value that can be aggregated — counted, summed, or averaged. Examples include Count of Orders, Sum of Revenue, or Average Session Duration.

In a line graph, the dimension (your time period) goes on the X-axis (the horizontal line), and the measure (your numeric value) goes on the Y-axis (the vertical line).

Free PDF · the crash course

AI Agents for Marketing Crash Course

Learn how to deploy AI marketing agents across your go-to-market — the best tools, prompts, and workflows to turn your data into autonomous execution without writing code.

How to Create a Line Graph in Looker: A Step-by-Step Guide

Ready to build one? Let's walk through the process of creating a simple line graph that shows weekly user sessions. We'll start from a blank slate, also known as an "Explore" in Looker.

Step 1: Choose Your Explore

Your first step is to pick the dataset you want to work with. In Looker, these are called "Explores." Each Explore is a curated dataset for a specific purpose, like "Website Analytics Data" or "Salesforce Opportunity Data." Find and click on the Explore that contains the data you need.

Step 2: Select Your Time Dimension

Once you're in the Explore, you’ll see a list of available fields (dimensions and measures) on the left sidebar. Our goal is to show a trend over time, so we need to select a time-based dimension. Find a date field, often named something like "Event Date" or "Created Date." Looker groups different timeframes under these fields. Click to expand it and select the appropriate granularity, such as Week. This will form the X-axis of your graph.

Step 3: Choose Your Measure

Now you need to tell Looker what numerical value to plot over time. From the same field list on the left, find the measure you want to track. For this example, let's click on Session Count. This will be the Y-axis of your graph.

Step 4: Add Any Necessary Filters

Often, you don't want to analyze all your data since the beginning of time. Use the "Filters" section at the top of the page to focus your analysis. A common filter is the date range. Click into the filter bar, select your date dimension (e.g., "Event Date"), and choose a time range like "is in the last 90 days."

GraphedGraphed

Build AI Agents for Marketing

Build virtual employees that run your go to market. Connect your data sources, deploy autonomous agents, and grow your company.

Watch Graphed demo video

Step 5: Run the Query

With your dimension, measure, and filter selected, click the "Run" button in the top right. Looker will process your request and, by default, display the output as a data table — a simple list of weeks and their corresponding session counts.

Step 6: Select the Line Chart Visualization

Now for the final step. Above the data table, you'll see the "Visualization" pane. Look for the 'Line' icon among the chart options and click it. Instantly, Looker will transform your data table into a clean, easy-to-read line graph. Just like that, you’ve created your first visualization!

Customization Tips: Making Your Line Graph Shine

A basic line chart is good, but a well-customized one is great. Looker offers a ton of options to make your visualization clearer and more insightful. Simply click the "Edit" button (gear icon) in the top right of the visualization pane to open up the settings menu.

Plot Options

These settings affect the overall appearance and behavior of your lines.

  • Series Positioning: You can choose "Grouped" for a standard line chart or "Stacked" if you want to show how different series contribute to a whole.
  • Line Interpolation: Change the style of the line. "Linear" gives you straight, angular lines, while "Monotone" creates smoother curves.
  • Show Points: Toggle visible markers for each data point on your line. This can make the exact value for each period easier to spot.

X & Y-Axis Settings

Get your axes just right for maximum clarity.

  • Axis Name: Replace the default field names with something more descriptive. For example, change "Event_Date_Week" to "Week" and "Session_Count" to "Number of Sessions."
  • Label Format: Customize how values are displayed on your axes. For a revenue chart, you could format Y-axis labels as currency ($1,000).
  • Show Gridlines: Toggle gridlines on or off to reduce visual clutter.
  • Add a Trend Line: In the "Reference Lines" section of the Y-axis menu, you can add a trend line. Select a type like "Linear" to automatically draw a line that shows the overall direction of your data — an incredibly useful feature for identifying long-term growth or decline at a glance.

Series Customization

If you're plotting multiple lines on one graph (for example, comparing several different traffic sources), you can customize each one individually.

  • Colors: Assign distinct colors to make each line easily distinguishable.
  • Value Labels: Add the exact numeric value above each data point on the line. This is great for presentations where you want to call out specific numbers without forcing the viewer to trace their finger from the point to the axis.

Free PDF · the crash course

AI Agents for Marketing Crash Course

Learn how to deploy AI marketing agents across your go-to-market — the best tools, prompts, and workflows to turn your data into autonomous execution without writing code.

Putting It Into Practice: Using Pivots for Comparison

So far, we've only built a graph with a single line. But what if you want to compare multiple categories over time in the same chart? This is where Looker's Pivot feature comes in. Pivoting a dimension essentially transforms its values into unique columns, creating a separate line for each.

Let's say you want to compare weekly sessions by Traffic Source (e.g., Google, Facebook, Direct). Here's how you'd do it:

  1. Keep your time dimension (Week) and measure (Session Count) selected.
  2. Find the dimension you want to compare — in this case, Traffic Source.
  3. Instead of just clicking it, click the "Pivot" icon next to the field name.
  4. Click "Run."

Your visualization will now show a multi-line graph, with a unique, color-coded line for Organic Search, Social Media, and any other traffic source. This is one of the most powerful features for comparative analysis in Looker.

Common Pitfalls and How to Avoid Them

As you build more line graphs, you might run into a few common issues. Here are some quick troubleshooting tips:

  • "My chart looks like a messy zig-zag." This usually happens when your time dimension is too granular. For example, plotting a measure by 'second' or 'minute' over a long period will create a chaotic-looking chart. The fix is to choose a broader time dimension, like 'Hour,' 'Day,' or 'Week,' to smooth out the noise.
  • "There are gaps in my line." This means you have null (missing) values for certain time periods. In the 'Plot' settings, look for the 'Null points' option. You can choose to leave a gap, connect the line over the gap ('Linear Interpolation'), or treat the null value as a zero.
  • "The scale makes it hard to see changes." If you have one or two massive outlier data points, they can squash the rest of your line graph, making smaller fluctuations invisible. Consider adding a filter to exclude the outliers or, for very large ranges in growth, try switching the Y-axis scale from 'Linear' to 'Log' in the Y-axis settings.

Final Thoughts

Creating a line graph in Looker is a simple process once you're comfortable with dimensions, measures, and the Explore interface. By starting with a clear question and then layering on filters, pivots, and formatting, you can turn a basic trendline into a powerful analytical tool for tracking performance and sharing crucial business insights.

While Looker is great for teams with data analysis resources, not everyone has the time to master a new business intelligence tool. We created Graphed to remove that barrier. It connects directly to your data sources, allowing you to ask questions in plain English. Instead of clicking and configuring menus to build a chart, you can simply type, "Show me my weekly sales from Shopify and revenue from Stripe as a line graph," and get a real-time, interactive dashboard in seconds.

Related Articles