If your scores are in column A, from A2 to A41, this formula gives the Net Promoter Score in one cell. It works the same in Excel and Google Sheets:
=(COUNTIF(A2:A41,">=9")-COUNTIF(A2:A41,"<=6"))/COUNT(A2:A41)*100
COUNT only counts cells that hold numbers, so blank rows for people who skipped the question don't drag the score down. For CSAT on a 1–5 scale in column B, the share of satisfied responses is:
=COUNTIF(B2:B31,">=4")/COUNT(B2:B31)
Format that cell as a percentage. A spreadsheet gives you the score but not the confidence interval, so paste the same column into the calculator above when you need to know whether a change is real.