Excel Trendlines: Which Type Should You Use for Your Data?

How-to basics · Updated November 21, 2026

Use a linear trendline when your data changes at a roughly steady rate; choose another type only when the data’s shape supports it. In Excel, exponential fits proportional growth or decline, logarithmic fits a rapid change that levels off, polynomial fits a curved pattern, power fits a relationship such as scaling, and moving average smooths short-term fluctuations.

Start with the shape and meaning of the data

A trendline is a mathematical curve or straight line added to a chart to summarize the relationship between variables. It can make a broad pattern easier to see, but it is not proof that the pattern will continue or that one variable causes another. The right choice depends on what the values represent, how they change, and what you want the chart to communicate.

Before choosing a type, make a scatter chart and inspect the points. Look for a roughly straight cloud, a curve that bends consistently, or noisy values that move around a slower trend. Also ask what the horizontal axis means. If it is a measured number, such as elapsed time, distance, or dosage, a scatter chart preserves the spacing between those x-values. A line chart often treats its horizontal labels as categories spaced evenly, even if the underlying dates or numbers are not evenly spaced.

  • Use a scatter chart when both axes represent numeric measurements and the spacing between x-values matters.
  • Use a line chart when the horizontal axis is a sequence of categories or regular time periods, such as months.
  • Do not select a trendline just because one option produces a high R-squared value; check whether its shape makes sense for the situation.

What the six Excel trendline types mean

Excel offers six main trendline types. Their names describe different mathematical shapes, not a ranking from simple to best. A more flexible curve can follow the plotted points more closely while still giving a misleading summary.

  • Linear: A straight line representing a steady change in y for each unit change in x. It is the best first comparison for many datasets.
  • Exponential: A curve suited to a relationship where the rate of change is proportional to the current value, such as some early-stage growth or decay patterns. Its y-values must be positive for Excel to fit this type.
  • Logarithmic: A curve that changes quickly at first and then levels off, or the reverse depending on its direction. The x-values must be positive.
  • Polynomial: A curved line that can bend one or more times. Excel lets you set its order; higher orders make more complex shapes and can overfit a small dataset.
  • Power: A relationship in which y varies as a power of x, often useful for scaling patterns. Both x and y values must be positive.
  • Moving Average: A smoothed line based on averages of neighboring points. It can reveal a broad direction in noisy data, but it is not a conventional equation fitted to all points.

When a linear trendline is the right choice

Choose linear when the plotted points cluster around a straight path and a constant rate of change is a reasonable description. For example, if a machine produces about the same additional number of units for each extra hour of operation, a linear trendline may summarize output over the observed range. A linear line is also a useful baseline: compare it with a more complex curve only if the data show a meaningful, consistent bend.

Excel’s linear trendline reports a slope and an intercept when you display its equation. The slope describes the estimated change in the vertical variable for a one-unit change in the horizontal variable, using the chart’s units. The intercept is the model’s estimated y-value at x = 0. That value may have no practical meaning if zero is outside the observed range. Do not force a line through zero simply to make the chart look tidy; do so only when the underlying relationship justifies that constraint.

When to use exponential, logarithmic, or power

These three curved types can look similar over a short range, so choose based on the process behind the data rather than appearance alone. An exponential pattern changes by a roughly constant percentage over equal x-intervals. A familiar example is a quantity that grows by the same proportion each period, although real-world growth often changes as conditions change. Exponential curves can rise or fall sharply, so extending one far beyond the observations may create implausible estimates.

A logarithmic pattern often describes fast early gains followed by smaller gains. For instance, a learning measure might improve rapidly with initial practice and then improve more slowly. That is only a possible shape, not a guarantee that a logarithmic model explains the process. A power relationship is useful when scaling is central—for example, when a measured quantity changes in a consistent nonlinear way as the size of an object changes. Check that positive-value requirements are met before selecting logarithmic, exponential, or power; Excel may be unable to calculate a trendline when the data include invalid values for that model.

Polynomial curves and the risk of overfitting

A polynomial trendline is appropriate when the data show a clear curve or several broad bends that a straight line cannot represent. In Excel, you choose an order, from 2 through 6. A second-order curve can make one broad bend; higher orders can create additional turns. For example, a smooth rise followed by a fall might warrant testing a low-order polynomial if that shape is meaningful in context.

More bends do not automatically mean a better model. A high-order polynomial can pass close to every point in a small sample yet swing wildly between observations or outside the charted range. That is overfitting: the curve captures peculiarities of the measured sample rather than a dependable underlying relationship. Begin with the lowest order that represents a plausible pattern, and compare the curve with the data and with a simpler alternative. A polynomial is also not a good way to represent recurring seasonality; a periodic model or a chart organized by season may be more appropriate.

Moving average: smoothing, not forecasting

Use a moving-average trendline when individual observations are noisy and your immediate goal is to make short-term variation less distracting. The period sets how many neighboring points are used in each average. A shorter period follows local changes more closely; a longer period produces a smoother line but can hide meaningful turning points. If monthly sales swing sharply from month to month, comparing several reasonable periods can show how sensitive the apparent direction is to the smoothing choice.

A moving average should not be mistaken for a fitted relationship or a reliable forecast. It does not explain why values changed, and smoothing can make a chart look more certain than the underlying data warrant. In particular, a longer period can make a genuine recent shift appear late. State the period in the chart or its notes so readers know how much smoothing they are seeing.

Add and format a trendline in Excel

In Excel for Microsoft 365 on Windows, create a chart, select it, and use Chart Design > Add Chart Element > Trendline > More Trendline Options. In the Format Trendline pane, select the data series and the trendline type. For a polynomial, set the order; for a moving average, set the period. You can also select options to display the equation on the chart or show the R-squared value.

Displaying an equation is useful when readers need the fitted relationship, but format it carefully: a chart equation may round coefficients, and calculations made from rounded values can differ from the fit. The R-squared display is a summary of how well the chosen trendline corresponds to the plotted data; it does not establish that the model is appropriate or predictive. Avoid cluttering a presentation chart with both values unless they help answer a specific question.

On Mac, select the chart and use the Chart Design tab’s trendline controls; the exact layout can vary by Excel release. In Excel for the web, available chart-formatting controls may differ from the Windows desktop app. If a named option or pane is not available in your version, check the chart formatting controls for that version rather than assuming every desktop command is present.

Compare candidate models without trusting one number

Excel’s R-squared value is useful as one comparison, but it should not decide the model by itself. A more complex curve often achieves a higher R-squared because it can follow the observed points more closely. That does not mean it will describe new data better. R-squared also cannot tell you whether the selected curve is sensible for the subject, whether unusual points are distorting it, or whether the relationship is causal.

Use a practical review before settling on a trendline:

  1. Check for data-entry errors, missing observations, and unusual points that may have a legitimate explanation.
  2. Plot the observations first and choose a simple candidate based on the visible pattern and subject knowledge.
  3. Compare the candidate line with the points across the full observed range, not just at one end.
  4. Check whether the model’s assumptions and value restrictions fit the data.
  5. Be cautious about forecasting beyond the observed x-values; a trendline extends mathematically, but the real process may change.

Common trendline problems and misconceptions

If Excel will not add a trendline or the expected type is unavailable, check the chart type and the selected series. Trendlines are intended for supported chart series, such as scatter and many standard line or column charts; some chart types and layouts do not support them. A chart with several series may need a trendline added to each relevant series separately. Selecting the chart area rather than the data series can also make the controls appear unavailable or apply changes somewhere other than intended.

Another common problem is using a line chart for irregular numeric x-values. If observations occur after 1, 2, and 10 days, a category-style axis can place those three labels at equal visual intervals. A scatter chart uses the actual numeric spacing and is usually the better choice for analyzing how y changes with x. Also remember that a line through observations is a summary, not evidence of cause and effect. For example, two measures that rise together over time may both be responding to a third factor.

Frequently Asked Questions

Which Excel trendline is best for forecasting?

There is no universally best trendline for forecasting. Choose a model that fits the subject and observed pattern, then treat projections—especially beyond the measured range—as uncertain. A high R-squared value alone is not enough to establish forecast accuracy.

Should I use a linear or polynomial trendline?

Use linear if the relationship is roughly straight. Use a low-order polynomial only when the data show a sustained curve that has a sensible explanation. A high-order polynomial can fit sample points closely but behave unpredictably between or beyond them.

Why can’t I add an exponential trendline in Excel?

Excel’s exponential trendline requires positive y-values. Check the selected series for zero or negative values and confirm that you selected a supported chart series. If those values are real, do not remove them just to force a fit; choose a model that can represent the actual data.

What does R-squared mean on an Excel trendline?

R-squared is a fit statistic for the displayed trendline and data. A value closer to 1 indicates a closer fit by that statistic, but it does not prove causation, validate the model’s assumptions, or guarantee accurate future predictions.

Can I use a moving-average trendline to predict future values?

A moving average is mainly a smoothing tool. It summarizes neighboring observations and can help reveal a broad direction, but it does not by itself provide a dependable forecast model or explain the forces behind the changes.

Related

Try it: the Date Difference Calculator: days, months, years and weekdays between two dates, with the DATEDIF formulas.

More in How-to basics

Sources: Function behaviour and menu paths: Microsoft Support documentation for Excel. Method & sources

Spotted an error in this guide? Let us know.