Goal Seek in Excel: Step-by-Step Instructions

How-to basics · Updated November 3, 2026

Goal Seek in Excel: Step-by-Step Instructions

To use Goal Seek in Excel for Microsoft 365 on Windows, select Data > What-If Analysis > Goal Seek, choose a formula cell under Set cell, enter the result you want under To value, and select the input cell Excel may change under By changing cell. Select OK to find an input that produces your target result.

What Goal Seek does

Goal Seek works backward from a result. You give Excel a target value for a formula, then identify one input cell that can be adjusted. Excel repeatedly changes that input and recalculates the formula until it finds a value that meets the target, or gets as close as it can under its calculation limits.

For example, a business might know its desired profit and want to find the sales price needed to reach it. A student might know a required course average and want to find the exam score that would produce it. In both cases, the result depends on a formula, and one input is unknown.

Goal Seek is part of Excel’s What-If Analysis tools. It is not a forecasting feature: it does not decide whether a target is realistic, estimate future conditions, or explain which assumptions are sensible. It simply solves for one input within the formula model you provide.

Prepare the worksheet first

Set up the calculation before opening Goal Seek. The target cell must contain a formula that depends, directly or indirectly, on the input cell you want Excel to change. The changing cell should contain a value, not a formula. Keep the relationship between the cells easy to inspect so you can verify the answer afterward.

  • Put the unknown input in its own cell, such as a price, quantity, score, or percentage.
  • Write a formula in a separate result cell that uses that input.
  • Decide on a target result and check that the units and signs make sense.
  • Keep other assumptions fixed while solving; Goal Seek changes only one cell.

Save the workbook before making a change if you want to preserve the original input. Goal Seek updates the changing cell when you accept its result, so the worksheet may no longer show the starting assumption.

Goal Seek in Excel: step-by-step

  1. Check the formula. Select the result cell and confirm that it contains a formula, not a typed number. Make sure the formula depends on the input cell you intend to adjust.
  2. Open Goal Seek. On the Windows ribbon, select Data > What-If Analysis > Goal Seek. In some window sizes, the What-If Analysis control may appear within the Forecast group on the Data tab.
  3. Set the result cell. In the Goal Seek dialog, enter the formula cell in Set cell, or select that cell on the sheet. This is the result Excel will try to match to your target.
  4. Enter the target. In To value, type the desired result as a number. For example, type 1000 to seek a result of 1,000. Do not enter a formula in this box.
  5. Choose the input to adjust. In By changing cell, enter or select the single input cell Excel is allowed to change. It must be a cell that the formula uses, and it cannot be the formula cell itself.
  6. Run and review. Select OK. Excel calculates a candidate and displays a Goal Seek Status message indicating whether it found a solution. Select OK in that message to keep the result, or Cancel to restore the previous value.

After accepting the result, inspect the changing cell and the formula cell. Excel has changed the input value; it has not created a new formula or permanently recorded a separate scenario. Add a note, label, or copied value elsewhere if you need to document the assumptions and result.

Worked example: find the price for a target profit

Suppose a simple model has a unit price in B2, expected units sold in B3, and fixed costs in B4. Put the calculated profit in B5. With unit price in B2, units sold in B3, fixed costs in B4, and profit in B5, enter =B2*B3-B4 in B5. For an illustrative starting setup, enter 20 in B2, 100 in B3, and 1,800 in B4. The formula returns 200 because 20 multiplied by 100 is 2,000, and 2,000 minus 1,800 is 200.

Now suppose the target profit is 1,000 and units sold and fixed costs are to remain unchanged. Open Goal Seek and use these entries:

  • Set cell: B5, the profit formula.
  • To value: 1000.
  • By changing cell: B2, the unit price.

Excel should find a price of 28. At that price, 28 multiplied by 100 is 2,800; subtracting 1,800 in fixed costs gives a profit of 1,000. The calculation demonstrates what Goal Seek does, but it assumes the number of units sold stays at 100 even when price changes. If demand would change with price, the worksheet needs a more realistic model before the result can be treated as useful.

What Goal Seek can and cannot solve

Goal Seek is designed for one target formula and one adjustable input cell. You cannot ask it to change several assumptions at once, impose a range such as “price must be between 10 and 30,” or maximize profit while following multiple constraints. Those are different kinds of optimization problems.

The method also depends on the formula and starting values. Some equations have more than one possible solution, while others have no solution for the chosen target. In those cases, Excel may converge to one answer based on its starting point, or report that it could not find a solution. A displayed answer is a mathematical result for the worksheet model, not proof that the assumptions behind the model are correct.

Goal Seek is iterative, so its result is generally an approximation within Excel’s calculation tolerance rather than a guarantee of exact equality at every displayed decimal place. Increase the number of displayed decimal places in the result and changing cells when precision matters, then recalculate the formula to check how close it is to the target.

Common problems and how to fix them

  • “Set cell” is not a formula. Goal Seek needs a formula as the target result. Put the calculation in a worksheet cell and select that cell, rather than selecting a typed value.
  • The wrong input changes, or nothing useful happens. Confirm that the changing cell is an input used by the target formula. If the formula does not depend on it, changing it cannot move the result toward the target.
  • The result is far from the expected answer. Review cell references, units, signs, and fixed assumptions. Check that the target is in the same units as the formula result—for example, dollars rather than a percentage.
  • Excel reports it could not find a solution. The target may be unreachable, the formula may not respond to the input, or the starting value may lead the iterative calculation away from a solution. Try a sensible starting value and test whether nearby input values move the result in the expected direction.
  • The answer appears rounded. Cell formatting can hide decimals. Increase the displayed decimal places and check the underlying value in the formula bar or with a more precise number format.
  • The worksheet changes after accepting. This is expected: Goal Seek writes its solution into the changing cell. Use Cancel in the status dialog to discard the proposed value, or restore the original input if you already accepted it.

Excel for Mac and Excel for the web

In Excel for Microsoft 365 on Windows, the standard ribbon path is Data > What-If Analysis > Goal Seek. In Excel for Mac, look on the Data tab for What-If Analysis and then Goal Seek; ribbon layout and grouping can vary with the app version and window width. The dialog uses the same three fields: Set cell, To value, and By changing cell.

Excel for the web does not provide the desktop Goal Seek command. If you do not see it in the browser, open the workbook in the desktop Excel app and use the Data tab there. You can then save the workbook and continue working with it online, but the solving operation itself requires the desktop feature.

Goal Seek compared with other Excel tools

Choose a tool based on the question you are trying to answer:

  • Goal Seek: Find one input that produces a specified value in one formula cell. It is the direct choice for a single-variable “what input gives me this result?” question.
  • Solver: Find a best or target result while changing multiple cells and applying constraints. Solver is an Excel add-in and may need to be enabled; it is more suitable for problems such as maximizing profit subject to capacity limits.
  • Data Tables: Compare how formula results change across one or two sets of trial input values. A data table shows a range of outcomes rather than solving for one exact target input.
  • Manual calculation or algebra: If the equation is simple and can be rearranged safely, solving it directly may be quicker and easier to audit. For complex formulas, Goal Seek can avoid rearranging the equation by hand.

These approaches are not interchangeable. A data table can help you see the shape of a result, Solver handles broader optimization, and Goal Seek answers a focused one-input question.

Frequently Asked Questions

Where is Goal Seek in Excel?

In Excel for Microsoft 365 on Windows, select Data > What-If Analysis > Goal Seek. On Mac, look for Goal Seek under What-If Analysis on the Data tab. The feature is not available as a command in Excel for the web.

Why is Goal Seek grayed out or unavailable?

Check that you are using the desktop Excel app and that a worksheet is active. Excel for the web does not offer the Goal Seek command. If the workbook is open in a browser, choose the option to open it in the desktop app.

Can Goal Seek change more than one cell?

No. Goal Seek changes one input cell for one formula result. Use Solver when a problem requires multiple changing cells or constraints, or use another method suited to the model.

Does Goal Seek change the formula?

No. It changes the value in the cell you specify under By changing cell. The target formula stays in place and recalculates using the new input.

Can I use Goal Seek with a percentage or date?

Yes, if the target formula uses the input and the target is entered as the underlying numeric value Excel expects. For a percentage, enter the numeric equivalent—for example, 10% is stored as 0.1. For dates, ensure the formula and target refer to meaningful Excel date values, then verify the displayed result and its number format.

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.