How to convert letter grades to GPA points in Excel
Formula (Excel and Google Sheets)
=XLOOKUP(C2,$F$2:$F$11,$G$2:$G$11)Keep a grade-to-points table and look each grade up with an exact match: =XLOOKUP(C2,$F$2:$F$11,$G$2:$G$11).
- Result on the example
- one result per row in
D2, filled down toD7 - Works in
- Excel 2021, 2024 and Microsoft 365
- Google Sheets
- Same formula
See it work
The formula is already in D2, filled down to D7. Change any input and the result updates, or edit the formula to experiment.
How it works
XLOOKUP finds the letter grade in F2:F11 and returns the points beside it. It is an exact match, so "B+" and "B" are different rows. The $ keeps the grade table fixed while the formula fills down the courses.
=XLOOKUP(C2,$F$2:$F$11,$G$2:$G$11)Result3.3
C2"B+"The value in C2.
$F$2:$F$1110 rows × 1 col: "A", "A-", "B+", "B", …A range: 10 cells in one column.
$G$2:$G$1110 rows × 1 col: 4.0, 3.7, 3.3, 3.0, …A range: 10 cells in one column.
XLOOKUP(C2,$F$2:$F$11,$G$2:$G$11)3.3XLOOKUP: Searches one range and returns the matching item from another.- lookup_value
C2"B+" - lookup_array
$F$2:$F$1110 rows × 1 col: "A", "A-", "B+", "B", … - return_array
$G$2:$G$1110 rows × 1 col: 4.0, 3.7, 3.3, 3.0, …
- lookup_value
In Google Sheets
The same formula works in Google Sheets: =XLOOKUP(C2,$F$2:$F$11,$G$2:$G$11). We ran it in Google Sheets mode on the same data and it returns the same results.
Other ways to do it
Each one was run on the same example sheet.
| Formula | Result | When to use it |
|---|---|---|
| =VLOOKUP(C2,$F$2:$G$11,2,FALSE) | 3.3, 3.7, 3.0… | Works in every version. Keep FALSE: an approximate match on letter grades sorts them alphabetically and returns wrong points. |
Common mistakes
- A grade typed with a different dash (A– instead of A-) or a trailing space returns #N/A. Use data validation with the table as the list.
- Pass/fail and withdrawn grades (P, W) aren't in the table. Add them with blank points, or wrap the lookup in IFNA.
Try it yourself
Same data, empty answer cell. Your formula is graded instantly, then re-checked on changed data, so a typed-in number won't pass.
Convert letter grades to GPA points
D2, return the grade points for the letter grade in C2 using the table in F2:G11, then fill down to D7.Questions
How do I calculate the GPA weighted by credits?
Multiply points by credits and divide by the credits: =SUMPRODUCT(B2:B7,D2:D7)/SUM(B2:B7).
How do I convert a percentage to a letter grade first?
Use an approximate match on a table of minimum scores, such as =XLOOKUP(score,min_scores,letters,,-1).
Checked by running on 2026-10-30: every formula and result on this page was calculated by the Spreadsheet Practice formula engine, in both Excel and Google Sheets modes.