Formulas contain information to perform a numerical calculation such as adding, subtracting, or multiplying. All formulas must start with an equal sign (=), followed by:
- Values or cell references joined by an operator. Example: =5+3 or =A1+A2.
- A function name followed by parentheses containing function arguments. Functions are the most common way to enter formulas in Excel. Example: =SUM(A1:A2).
Here's how to create a formula in Excel.
- Click the cell where you want to add the formula.
- Press =.
Now you must specify what to calculate.
- Enter the formula.
Your formula should include:
- Values, like the number 5.
- Cell References, like cell A1. You can add cell references by typing them or clicking the cell you want to reference.
- Operators, or math symbols you want to use in your calculations:
+ (add)
- (subtract)
* (multiply)
/ (divide)
- Click the Enter button or press Enter when you're finished entering your formula.
If you entered the formula correctly, the results of the formula will appear in the cell.
Operator |
Formula Example |
Description |
= |
|
All formulas must start with an equal sign. |
+ |
=2+2 |
Add values. |
- |
=A1-B1 |
Subtract values. |
* |
=B1*2 |
Multiply values. |
/ |
=A1/C2 |
Divide values. |
SUM |
=SUM(A1:A3) |
Totals numbers in a range. |
Average |
=AVERAGE(A2,B1,C3) |
Averages numbers in a range. |
If you change the data referenced in a formula, Excel will automatically recalculate the formula to include the updated data.
- Change the values of the cells that are referenced in a formula.
Any formulas are automatically recalculated with the changes.
It's easy to make changes to a formula too.
- Click the formula you want to edit.
- Click in the Formula bar.
- Edit the formula.
- Press Enter.
Excel updates the value of the cell(s) that your formula calculates.
The Formulas tab on the ribbon contains multiple commands that you can use when working with formulas.
- Click the Formulas tab.
The Formulas tab displays. There are two main areas to the tab:
- The left side has options to help you create formulas and
- The right side has options to help fix errors.