Excel 111th: Ordinal Suffix Formulas That Get 11th to 113th Right
Why Excel formulas turn 111 into 111st, and which ordinal suffix formulas, rank formulas and conditional formats handle 11th, 12th, 13th and 111th correctly.
If you are searching for “excel 111th”, you almost certainly want Excel to write 111th (not 111st), along with 11th, 12th and 13th. The fix is to check the last two digits with MOD(A1,100) before looking at the last digit, and the one-line formula below does exactly that.
Excel has no built-in ordinal function or number format for this, as Office Watch and the AskWoody forum both point out. So you either build the suffix with a formula (which gives you text) or fake it with conditional formatting (which keeps a real number). Both are covered below. These methods use standard worksheet functions and work the same way as of November 2026.
The quick answer: a formula that handles 111th
Put your number in A1 and use:
=A1&IF(OR(MOD(A1,100)={11,12,13}),"th",CHOOSE(MIN(5,RIGHT(A1)+1),"th","st","nd","rd","th"))
This version was shared on the AskWoody forum. Here is what it does with some tricky inputs:
| Number | Last two digits | Result |
|---|---|---|
| 1 | 01 | 1st |
| 11 | 11 | 11th |
| 21 | 21 | 21st |
| 101 | 01 | 101st |
| 111 | 11 | 111th |
| 112 | 12 | 112th |
| 113 | 13 | 113th |
| 122 | 22 | 122nd |
Why naive formulas get 111 wrong
Most quick formulas look only at the last digit: 1 means “st”, 2 means “nd”, 3 means “rd”, everything else “th”. That breaks for any number ending in 11, 12 or 13, including 111, 211 and 1,012. English treats those as “th” numbers.
The fix is the MOD(A1,100) test. According to Microsoft’s MOD documentation, MOD returns the remainder after division, so MOD(111,100) is 11. If that remainder is 11, 12 or 13, the formula returns “th” and stops there. Only otherwise does it look at the last digit.
RIGHT(A1) gets that last digit. Microsoft’s RIGHT documentation notes that if you leave out the character count it defaults to 1. MIN(5, ...) makes sure every digit from 4 to 9 (and 0) lands on “th”.
Three formula options compared
Several reliable formula patterns are in common use. They all produce the same result for positive whole numbers. They just differ in how easy they are to read.
| Approach | Best for | Notes |
|---|---|---|
| IF + OR + CHOOSE (above) | Most people | Easy to read; exceptions listed explicitly |
| IF + AND + CHOOSE with ABS | Lists that may contain negatives | The pattern Exceljet uses for its general version |
| MID on a “thstndrdth” string | Compact, single-function fans | Shortest, hardest to read |
Option 2: the Exceljet-style MOD and CHOOSE formula
Exceljet’s ordinal suffix guide uses an IF(AND(...)) test to trap the 11 to 13 range, then a 10-item CHOOSE for every other last digit. Written out in full, that pattern looks like this:
=A1&IF(AND(MOD(ABS(A1),100)>10,MOD(ABS(A1),100)<14),"th",CHOOSE(MOD(ABS(A1),10)+1,"th","st","nd","rd","th","th","th","th","th","th"))
ABS stops negative numbers from breaking the logic. Some versions online use >=10 and <=14 instead. That also catches 10 and 14, but both take “th” anyway, so the result is the same.
Option 3: the compact MID formula
An ExcelForum tutorial offers a very short version that pulls two letters out of the string “thstndrdth”:
=A1&MID("thstndrdth",MIN(9,2*RIGHT(A1)*(MOD(A1-11,100)>2)+1),2)
The (MOD(A1-11,100)>2) part is FALSE (zero) when the last two digits are 11, 12 or 13. That makes the start position 1, which is “th”. It works, but it is harder to check later, so leave a cell comment if you use it in a shared workbook.
Adding ordinals to a ranking
A common reason to need 111th is a leaderboard or sales ranking. Exceljet’s approach is to calculate the rank first and then add the suffix:
- In C2, calculate the rank, for example
=RANK(B2,$B$2:$B$200). - In D2, use any formula above, with
C2in place ofA1. - Fill both columns down.
Two things to watch:
- Ties. RANK gives tied values the same rank and then skips the next one, so you might see two 4ths and no 5th. Exceljet covers a COUNTIF-based adjustment if you need unique ranks.
- Keep column C. The result in column D is text, so sort and filter on the numeric rank in C, not on D.
Ordinal dates: “November 11th”
For dates, apply the same logic to the day number. With a date in A1:
- Replace
A1in the formula withDAY(A1)to get the day plus suffix, for example 11th. - Join on the rest of the date with TEXT, for example
&" "&TEXT(A1,"mmmm yyyy").
The ExcelForum tutorial above covers ordinal dates in detail. As it stresses, the suffix is for display only. The underlying value is still the date or number.
Keeping the value numeric with conditional formatting
Every formula above turns your number into text. That matters if you need to sort numerically, total the column or point other formulas at it. As AskWoody contributors note, a single custom number format cannot switch between four suffixes. You can get the same visual result by layering conditional formatting rules, each applying its own custom format. This is the approach TechRepublic describes.
- Select the range, for example A1:A200.
- Go to Home > Conditional Formatting > New Rule > Use a formula to determine which cells to format.
- Add a rule for 11 to 13:
=AND(MOD(ABS(A1),100)>10,MOD(ABS(A1),100)<14). Click Format > Number > Custom and enter0"th". - Add rules for
=MOD(ABS(A1),10)=1with0"st",=MOD(ABS(A1),10)=2with0"nd", and=MOD(ABS(A1),10)=3with0"rd". - Give the range itself a default custom format of
0"th"(via Format Cells > Number > Custom) to cover every other number. - Open Manage Rules and move the 11 to 13 rule to the top, so it wins over the “st”, “nd” and “rd” rules.
Step 6 is the one people miss. If the “ends in 1” rule is checked first, 111 shows as 111st again. The basic TechRepublic rule set does not handle 11 to 13 on its own, which is why the extra rule is needed.
Which method should you use?
- One-off label or report text: the IF + OR + CHOOSE formula. It is the easiest to read and to audit later.
- Rankings you will sort: keep the numeric rank in one column and the ordinal text in another.
- A column that must stay numeric: conditional formatting, with the 11 to 13 rule on top.
Whichever you pick, test it with 11, 12, 13, 111, 112 and 113 before you share the workbook. Those are the numbers that catch out most suffix formulas.
Free apps worth trying
SponsoredSponsored links. Installing through them can earn us a commission, at no cost to you. Apps are free to download; some offer optional in-app purchases.
Frequently asked questions
Why does my Excel formula show 111st instead of 111th? +
Your formula is probably only checking the last digit, which is 1, so it picks "st". Numbers whose last two digits are 11, 12 or 13 always take "th", so the formula needs to test MOD(number,100) before it looks at the last digit.
Can a custom number format add st, nd, rd and th by itself? +
No. Forum experts and tutorial sites agree that a single custom number format cannot switch between four suffixes. You can get close with conditional formatting rules that each apply a different custom format, or use a formula that returns text.
Can I still sort or calculate with 111th after adding the suffix? +
Only if you added it with number formatting or conditional formatting, because the cell still holds the number 111. A formula like =A1&"th" returns text, so keep the original number in its own column for sorting and maths.
Does the formula work for dates, like the 11th of November? +
Yes. Wrap the date in DAY() so the formula works on the day number, then join the result to the rest of the date with TEXT(), for example the month and year.
Sources
- Rank with ordinal suffix - Exceljet (exceljet.net)
- Ordinal dates and numbers in Excel 2007 or later - ExcelForum (excelforum.com)
- Custom format for rankings - AskWoody (askwoody.com)
- Pro tip: Add an ordinal indicator to a value in Excel - TechRepublic (techrepublic.com)
- Office Watch: ordinal numbers in Excel (office-watch.com)
- MOD function - Microsoft Support (support.microsoft.com)
- RIGHT function - Microsoft Support (support.microsoft.com)