To run Goal Seek in Excel for Microsoft 365 on Windows, select the cell containing the formula you want to reach, then choose Data > What-If Analysis > Goal Seek. Enter the target result and the one input cell Excel may change, then select OK. Goal Seek calculates an input value that makes the formula produce the target, which is useful when you know the result you want but not the value needed to get there.
Before starting, make sure the result cell contains a formula that depends on the input cell you want Excel to adjust. For example, if you want to find the price that produces a certain revenue, your revenue formula must use the price cell. Goal Seek changes one input cell at a time, so it is not a tool for changing several assumptions together.
What You’ll Need
- A workbook open in the desktop version of Excel. Goal Seek is available in Excel for Microsoft 365 on Windows and Mac. Excel for the web does not provide the Goal Seek command; open the workbook in the desktop app to use it.
- A formula cell whose result you want to set to a target number.
- A separate input cell containing a starting value that the formula uses. It should be an editable value, not another formula.
- A numeric target and a reasonable starting estimate. The estimate can affect whether Excel finds a useful solution, especially with nonlinear formulas.
Step-by-Step
- Set up the input and result cells. Put the value Excel is allowed to change in one cell, and make the formula that calculates your result in another. For a simple revenue example, assume A2 contains the unit price, A3 contains units sold, and A4 is where revenue will be calculated. If A2 is 12 and A3 is 50, then A4 should calculate revenue using both cells. With price in A2, units in A3, and revenue in A4, enter
=A2*A3in A4. The result is 600. The cell references are important: Goal Seek cannot work if the formula does not use the input cell it will change. - Choose an initial value for the changing cell. Enter a sensible starting estimate in A2, or in the input cell in your own workbook. It does not have to be the final answer, but it must be a valid value for the formula. For example, a positive price is a more useful starting point than a text entry or a value that causes a division-by-zero error. Keep the formula cell visible so you can check how the result changes.
- Select the formula cell. Click A4 in the example, or select the cell containing the result formula in your own worksheet. Goal Seek uses the selected cell as the Set cell when you open the tool. Confirm that you selected the formula result, not the input cell or a nearby label.
- Open Goal Seek. On the Windows ribbon, select Data > What-If Analysis > Goal Seek. The Goal Seek dialog box opens with a Set cell field. In Excel for Mac, use the Data tab and choose What-If Analysis > Goal Seek; depending on the ribbon layout, the command may appear directly in the What-If Analysis menu. If you are in Excel for the web, choose to open the workbook in the desktop app.
- Check the Set cell field. It should refer to the formula cell, such as
$A$4. If it does not, click in the field and select the correct result cell on the worksheet. The Set cell must contain a formula; entering a target in a blank or constant-value cell will not give Goal Seek a formula to evaluate. - Enter the target result. In the To value field, type the numeric result you want the formula to return. For the example, enter
900to ask for revenue of 900. Enter a number rather than a currency symbol, explanatory text, or a formula. The cell’s number format can still display the result as currency after the calculation. - Specify the changing input cell. In By changing cell, enter or select
$A$2, the price cell in the example. This must be a single cell, and it must be used directly or indirectly by the formula in the Set cell. Do not select the result cell itself, a cell containing a formula, or a whole range. - Run the calculation and review the result. Select OK. For the example, Excel changes A2 from 12 to 18; A3 remains 50, and A4 becomes 900 because 18 multiplied by 50 is 900. Excel then reports whether it found a solution. Select OK in the status message to keep the result in the worksheet, or select Cancel to restore the values that were in the cells before the Goal Seek run.
- Check the assumptions before using the answer. Look at the new value in the changing cell and the resulting formula value. Confirm that the input is realistic and that the formula represents the relationship you intended. Goal Seek is a numerical calculation, not a check of whether the answer makes sense in your situation. If you want to keep the original scenario as well as the answer, record the starting input and result in another area or save a copy of the workbook before running Goal Seek.
Common Mistakes
- Selecting the wrong Set cell: The Set cell must be the formula whose result you want to reach. Selecting the input cell, a heading, or a calculated value that is unrelated to the target leaves Goal Seek with the wrong problem to solve.
- Using a formula as the changing cell: Goal Seek needs to write a value into the changing cell. If that cell contains a formula, Excel cannot treat it as a free input. Use a separate input cell and update the result formula to reference it.
- Choosing a cell the formula does not use: If the formula result stays unchanged when the selected input changes, Goal Seek has no effective way to reach the target. Check the formula’s references and select an input that actually affects it.
- Entering a target in the wrong way: The To value field expects a number. Type 900 rather than a currency-formatted string or a description such as “900 dollars.” Excel can apply the currency display through the cell’s number format.
- Expecting multiple inputs or restrictions: Goal Seek varies only one cell and does not enforce conditions such as “price must be at least 10” or “quantity must be a whole number.” It can return a mathematically valid result that breaks a real-world constraint.
- Overlooking a poor starting estimate: A result can depend on the formula’s shape and starting value. For formulas with powers, percentages, thresholds, or several possible solutions, an extreme starting value may lead to an unwanted solution or no convergence.
Tips
- Build and test the formula first. Change the input manually and confirm that the result responds as expected. This catches missing references and incorrect arithmetic before you start Goal Seek.
- Use a sensible starting point and valid ranges. If an input should be positive, start with a positive value. If you are solving for a rate, use a plausible rate rather than a very large or very small number. Try a different reasonable starting estimate if the first attempt does not converge.
- Think about units and precision. Decide whether your target is dollars, units, a percentage, or another measure. A displayed value rounded to two decimal places can hide a more precise underlying value. Click the result cell and inspect the formula bar or increase the displayed decimal places if exact precision matters.
- Save or record the original scenario. Goal Seek writes the solution into the changing cell. If you need to compare the original and adjusted assumptions, copy the relevant inputs and outputs first, or use a separate worksheet or workbook copy.
- Use Solver for a more complex model. If you need to change several cells, maximize or minimize a result, or enforce limits on inputs, use Excel’s Solver add-in rather than Goal Seek. Solver may need to be enabled first through Excel’s add-in settings.
- Keep formulas and inputs clearly labeled. Labels such as “Unit price,” “Units,” and “Revenue” make it easier to choose the correct cells in the dialog and review what Excel changed afterward.
Troubleshooting
- Goal Seek is missing from the menu: Confirm that you are using the desktop Excel app, not Excel for the web. In Excel for Windows, look under Data > What-If Analysis. In Excel for Mac, check the Data tab. If you are using a simplified ribbon, switch to the full ribbon or expand the relevant menu.
- Excel says the cell must contain a formula: Recheck the Set cell field and select the cell with the calculation. A value typed directly into a cell is not enough. If you expected a formula but see a fixed number, inspect the cell and recreate the formula if necessary.
- The changing cell does not affect the result: Inspect the formula in the Set cell and trace its references. Make sure the cell you selected as the changing cell is one of those references, either directly or through another formula. Also check whether a formula is using a fixed constant instead of the input cell.
- Goal Seek cannot find a solution: Try a different starting value that is closer to a plausible answer. Check for errors such as
#DIV/0!, invalid inputs, or a formula that cannot produce the target for any allowed value. For instance, a formula that always returns a positive square cannot produce a negative target. Confirm that the target is reachable before repeating the calculation. - The answer is unexpected or unrealistic: Check the formula, units, and changing cell, then repeat the calculation from another reasonable starting estimate. Some formulas have more than one possible solution, and Goal Seek may find a different one depending on the starting point. If the answer violates a business rule or another constraint, Goal Seek will not automatically correct it.
- The result is close but not exact: Goal Seek uses numerical iteration, so a tiny difference can remain between the formula result and the target. Review the underlying value rather than only the rounded display. If the difference is material, verify the formula and try a better starting value; do not treat rounding as proof that the model is correct.
Frequently Asked Questions
Can Goal Seek change more than one cell?
No. Goal Seek adjusts one changing cell to reach a target in one formula cell. For multiple changing inputs or constraints, use Solver if your Excel version has the Solver add-in available.
Does Goal Seek overwrite the changing cell?
Yes. When you accept the result, Excel places the calculated value in the changing cell. It does not automatically save the original input in a separate place, so record that value first if you need it.
Can I use Goal Seek when my result is a percentage?
Yes, as long as the result cell contains a formula and the target is entered as a number using the scale the formula expects. For a formula that returns 0.15 and displays it as 15%, enter 0.15 as the target, not 15.
Can Goal Seek find an exact answer?
It tries to find a value that makes the formula reach the target, but iterative calculations can leave a small difference. Check the actual cell value and precision, and remember that some targets may not be possible for the formula.
Does Goal Seek work in Excel for the web?
No. Open the workbook in the desktop version of Excel for Windows or Mac to use Goal Seek. You can still edit the workbook in a browser, but the Goal Seek command is not available there.
Will Goal Seek save a reusable scenario?
No. It changes a cell to the calculated answer but does not create a saved scenario or record the calculation history. Copy your starting values and results, or use Excel’s scenario tools if you need to keep and compare multiple sets of assumptions.
Related
- Excel Won’t Remove Duplicates? Causes and Fixes
- Excel Won’t Insert a Row? Causes, Fixes, and Workarounds
- Excel Print Area Greyed Out: Why It Happens and Fixes
Try it: the Date Difference Calculator: days, months, years and weekdays between two dates, with the DATEDIF formulas.
More in How-to basics
- Indent Within the Same Cell in Excel: Step-by-StepTo indent only one line within an Excel cell, insert a line break with Alt+Enter on Windows, then…
- Excel Not Moving From Cell to Cell? Fixes That WorkIf Excel is not moving from cell to cell when you press the arrow keys, turn off Scroll…
- Excel Solver With Integer Values: Setup and ExamplesYes. In Excel for Microsoft 365 on Windows, open Data > Solver, add an integer constraint to the…
- How to Copy Text With Track Changes in Microsoft WordTo copy text with its existing tracked edits, show all markup in the source document, select the passage,…
- How to Remove Formatting in Word Without Losing TextTo remove formatting in a Word document, select the text, then choose Home > Clear All Formatting. To…
- How to Center a Word in ExcelTo center a word in an Excel cell, select the cell, then choose Home > Center in the…
Sources: Function behaviour and menu paths: Microsoft Support documentation for Excel. Method & sources
Spotted an error in this guide? Let us know.