Cellwise Try it free

Excel guide · 4 min read

How to calculate GPA in Excel

Quick answerTurn each letter grade into points with a small grade table and VLOOKUP, then divide the total quality points by the total credits: =SUMPRODUCT(B2:B6,D2:D6)/SUM(B2:B6), where B holds credits and D holds grade points. Do not just AVERAGE the points: that ignores credit hours and gives the wrong GPA whenever courses carry different credits.

Sample data

Every result on this page was calculated from this sheet by the same spreadsheet engine the Cellwise app uses.

ABCDEFGHIJ
1CourseCreditsGradePointsGradePointsPrior creditsPrior GPA
2Calculus I4B+3.3A4453.42
3English Composition3A4A-3.7
4Biology4A-3.7B+3.3
5US History3B3B3
6Studio Art1A4B-2.7
7C+2.3
8C2
9D1
10F0

Step 1: put the grade scale in cells, not in the formula

The sample uses a common 4.0 scale with plus and minus grades in F1:G10 (A = 4.0, A- = 3.7, B+ = 3.3 and so on). Scales differ between schools: some give A+ a 4.3, some have no minus grades, some use a 5.0 scale for honors classes. Copy the scale from your school's catalog or transcript key into these cells and every formula below follows it.

Keeping the scale in a table means you never edit a formula when the scale changes, and anyone checking your sheet can see exactly which points you used.

Step 2: look up the points for each grade

In D2, look up the letter grade in the scale and return its points. FALSE forces an exact match, which matters here: with approximate match, A- and A could be confused because the table is not sorted the way approximate match needs. The dollar signs lock the scale so you can fill the formula down to D6.

VLOOKUP is not case-sensitive, so a grade typed as "b+" still finds B+. A grade that is not in the table (a typo, or a P for pass) returns #N/A, which is useful: it tells you a row needs attention.

=VLOOKUP(C2,$F$2:$G$10,2,FALSE)

Result: 3.3

Calculus I is a B+, which is worth 3.3 points.

Step 3: the weighted GPA

GPA is quality points divided by credits. Quality points for one course are credits times grade points: a 4-credit B+ is 4 x 3.3 = 13.2. SUMPRODUCT multiplies the two columns row by row and adds the results, so the whole calculation fits in one cell.

Here the quality points total 53.0 over 15 credits.

=SUMPRODUCT(B2:B6,D2:D6)/SUM(B2:B6)

Result: 3.5333333333 shows as 3.53 with Number format

53 quality points over 15 credits: a GPA of about 3.53.

Why AVERAGE gives the wrong answer

AVERAGE treats a 1-credit studio class the same as a 4-credit science course. In this term the A in Studio Art pulls the simple average up, because it counts as a full fifth of the grades even though it is only one fifteenth of the credits.

Use AVERAGE only if every course has the same credits. Otherwise use the SUMPRODUCT version.

=AVERAGE(D2:D6)

Result: 3.6

3.6, which overstates the real 3.53 GPA because credits are ignored.

Cumulative GPA: add this term to your record

To update a cumulative GPA, you need your previous total credits and previous GPA (both on your transcript). Turn the old GPA back into quality points by multiplying by the old credits, add this term's quality points, and divide by all the credits together. Averaging the old GPA and the term GPA would be wrong for the same reason as above: 45 earlier credits outweigh 15 new ones.

Prefer no helper column? In full Excel, =SUMPRODUCT(B2:B6,SUMIF(F2:F10,C2:C6,G2:G10))/SUM(B2:B6) looks up all the grades inside one formula. The helper column is easier to check, so it is the better choice for most people.

=(I2*J2+SUMPRODUCT(B2:B6,D2:D6))/(I2+SUM(B2:B6))

Result: 3.4483333333 shows as 3.45 with Number format

(45 x 3.42 + 53) / 60 credits: the cumulative GPA moves from 3.42 to about 3.45.

Round the result the way your school does

Wrap the GPA in ROUND(...,2) to show two decimals, or ROUNDDOWN(...,2) if your school truncates instead of rounding. A truncated 3.4999 is 3.49, a rounded one is 3.50, which can matter for honors cut-offs. If you only need it to look tidy, change the number format and keep the full value underneath.

=ROUND(SUMPRODUCT(B2:B6,D2:D6)/SUM(B2:B6),2)

Result: 3.53

3.53, rounded to two decimals.

Common mistakes

Pass/fail or withdrawn courses counted in the credits

A P or W has no grade points, but if its credits stay in SUM(B2:B6) they drag the GPA down. Leave those rows out of the range, or divide by =SUMPRODUCT(B2:B6*ISNUMBER(D2:D6)) so only graded credits count. Check your school's policy on which courses count.

Approximate match in the VLOOKUP

Leaving off FALSE (or using TRUE) makes VLOOKUP return the wrong points for letter grades. Always end the formula with ,FALSE.

Grades typed with spaces

A grade typed as "B+ " with a trailing space returns #N/A. Clean the column with TRIM, or look up TRIM(C2).

Forgetting the dollar signs on the scale

Without $F$2:$G$10 the scale range slides down as you fill, and lower rows return #N/A or wrong points.

FAQ

What is the formula for GPA in Excel?

Put credits in one column and grade points in another, then use =SUMPRODUCT(credits,points)/SUM(credits). That is total quality points divided by total credits.

How do I convert letter grades to points in Excel?

Make a two-column table of grades and points, then use =VLOOKUP(grade,table,2,FALSE) next to each course. XLOOKUP works too in Excel 365 and 2021 or later.

How do I calculate a weighted GPA for honors or AP classes?

Add the extra points in the scale itself, for example a separate row "A (Honors)" worth 5.0, or add a bonus column and use credits x (points + bonus) in the SUMPRODUCT. Use the weighting your school publishes.

Can Excel calculate GPA on a percentage scale?

Yes. Convert percentages to letters first with a sorted cut-off table and approximate-match VLOOKUP, then look up the points. The letter grade guide shows the cut-off table.

Functions used

Related guides

Updated