Asset 20 8 2
Does AI recommend your business? Run the free check →

Join 15,000 business owners, marketers and entrepreneurs. The Sunday newsletter you'll be annoyed only arrives once a week.

Article

How to Use Solver in Excel: Set It Up, Add Constraints and Pick a Solving Method

Solver is an Excel add-in that finds the best value for one formula cell, called the objective cell, by changing other cells within limits you set. You can ask it for the maximum, the minimum or a specific value, and it'll adjust up to 200 variable cells to get there.

Microsoft describes Solver as a tool for what-if analysis. Put simply, you use it to find the maximum or minimum of one cell by changing other cells. Microsoft's own example: change the amount of your projected advertising budget and see the effect on your projected profit.

The catch: switch Solver on first, and skip Excel for the web

Two things trip people up before they start. First, Solver isn't on by default. If the Solver command or the Analysis group isn't showing on the Data tab, Microsoft says you need to activate the Solver add-in first. Second, add-ins aren't supported in Excel for the web, so you can't run Solver in a browser. If you've got the desktop app, Microsoft says you can use the Open in Excel button and run it there.

The three parts of a Solver model

Every Solver problem has the same three parts. Microsoft's example (its US-dollar figures, as of October 2026) shows them clearly. The level of advertising in each quarter affects the number of units sold, which in turn drives sales revenue, expenses and profit.

PartWhat it does (Microsoft)In Microsoft's example
Variable cellsThe cells Solver is allowed to changeQuarterly advertising budgets, B5:C5
Constrained cellA cell that must stay within a limitTotal budget of $20,000, cell F5
Objective cellThe formula cell you want to maximise, minimise or hitTotal profit, cell F7, set to maximum

Solver keeps changing the advertising budgets, within the total limit, until total profit reaches the maximum possible amount. The variable cells must feed into the objective cell, directly or through other formulas, or Solver has nothing to work with.

How to use Solver in Excel, step by step

  1. Activate the Solver add-in if the Data tab doesn't show it.
  2. On the Data tab, in the Analysis group, select Solver.
  3. In Set Objective, enter the reference or name of the objective cell. It must contain a formula.
  4. Choose Max for the largest value, Min for the smallest, or Value Of and type the target.
  5. In By Changing Variable Cells, enter the cells Solver may change, separating ranges that aren't next to each other with commas.
  6. In Subject to the Constraints, select Add, enter the cell reference, choose the relationship and type the constraint value. Select Add for another, or OK to go back.
  7. Pick the solving method and select Solve.
  8. In the Solver Results dialog box, select Keep Solver Solution to keep the answer, or Restore Original Values to undo it.

Microsoft adds that you can stop a run at any point by pressing Esc. Excel then recalculates the sheet with the last values Solver found.

The constraint types you can add

RelationshipWhat it does (Microsoft)
<=, =, >=Compares the cell with a number, a cell reference, a name or a formula
intForces a whole number. The box shows integer
binForces a binary value. The box shows binary
difForces all the values to be different. The box shows alldifferent

One limit from Microsoft: int, bin and dif can only be applied to constraints on the decision variable cells, not on other cells. You can change or delete any constraint later by selecting it and choosing Change or Delete.

Choosing a solving method

Solver offers three methods in the Solver Parameters dialog box, and Microsoft's guidance on which to pick is short:

MethodUse for (Microsoft)
GRG NonlinearSmooth nonlinear problems
LP SimplexLinear problems
EvolutionaryNon-smooth problems

Under Options you can fine-tune each one on the All Methods, GRG Nonlinear and Evolutionary tabs. On the All Methods tab you can set a maximum solving time in seconds and a maximum number of iterations. If Solver hits either limit before it finds a solution, it shows the Show Trial Solution dialog box. The convergence setting controls how much relative change is allowed in the last five iterations before Solver stops; the smaller the number, the less change it allows.

Reports, scenarios and saved models

  • Reports: once Solver finds a solution, pick a report type in the Reports box and select OK. The report appears on a new sheet. If Solver doesn't find a solution, fewer reports or none are available.
  • Scenarios: select Save Scenario in the Solver Results dialog box and give it a name, to keep the values for later.
  • Trial solutions: tick Show Iteration Results under Options to see each trial, then choose Stop or Continue.
  • Saved models: use Load/Save to store a problem in a range of empty cells, so one sheet can hold more than one problem. Each worksheet also keeps its own Solver selections when you save the workbook.

Using Solver on a Mac

On Excel for Mac, the route is Data then Solver, and the dialog box works the same way: objective, variable cells, constraints, method, Solve. Microsoft's Mac version of the advertising example simply puts the budget constraint in cell D5 and the profit objective in cell D7.

Work with me

Want AI doing the heavy lifting in your marketing?

I build the systems that handle the boring 80 percent, so you get your week back. Done properly, with the human kept in.

Solver vs Goal Seek

If you only have one unknown, you don't need Solver. Goal Seek changes one input until a formula hits a target, and CFI even notes it as a way to find an IRR, by trying discount rates until net present value is zero. Solver is for when several cells can change at once and you've got limits they have to respect.

My verdict on Solver

Use Goal Seek for one unknown and Solver when several cells can change and you have limits. That's the whole decision. Solver looks intimidating, but the dialog box only asks three questions: what you want to maximise or hit, what Excel's allowed to change, and what rules it has to follow. It's at its best on planning sheets, like a monthly budget in Excel, where you've got a fixed pot and several places it could go.

Frequently asked questions

Where is Solver in Excel?

On the Data tab, in the Analysis group. If it isn't there, Microsoft says you need to activate the Solver add-in first.

Can I use Solver in Excel for the web?

No. Microsoft says add-ins aren't supported in Excel for the web. If you have the desktop app, use the Open in Excel button and run Solver there.

How many variable cells can Solver change?

Microsoft says you can specify up to 200 variable cells, and they must relate directly or indirectly to the objective cell.

Which Solver method should I choose?

Microsoft says GRG Nonlinear for smooth nonlinear problems, LP Simplex for linear problems and Evolutionary for non-smooth problems.

What's the difference between Solver and Goal Seek?

Goal Seek changes one input to hit a target. Solver can change several cells at once and respect constraints you set.

Published and maintained by the Lilach Bullock team, covering marketing, AI and business growth.
Your buyers are asking AI who to use. Does it say you?

See for free whether ChatGPT, Claude, Perplexity, Gemini and Google name you, and get the plan to become the answer.

Check my AI visibility →
Sundays only

Get the Sunday newsletter.

One email a week. AI experiments, marketing tactics, and the workflows Lilach is building right now in her own business.

Subscribe free

Let’s get your marketing running on AI.

Book a free 30-minute call

We figure out what you need, where AI fits in, and what working together would look like.

Book the call →

Or take the 30-second calculator

You’ll see the hours and the money quietly leaking out of your week, and the three workflows worth building first.

Take the calculator →

Or grab the free AI resource library

Prompt packs, templates, checklists, and swipe files. The exact tools I build for paying clients. Yours, free.

Get the library →
Keep reading

More from the blog.