How to Write 1st 2nd 3rd in Excel (3 Easy Ways)

We will use the following dataset. It has three columns B, C, and D for the Student ID, Name, and Position. You can see the position has ordinal numbers already, but they are not correctly formatted. We will rewrite 1st, 2nd, and 3rd in Excel in the correct format with superscript.

dataset of how to write 1st 2nd 3rd in excel


Method 1 – Formatting Text Values as Superscripts to Write 1st, 2nd, 3rd in Excel

We have used the sample dataset where the positions are not formatted correctly.

Formatting Text Values as Superscripts to Write 1st 2nd 3rd in Excel

Steps:

  • Select the last portion of the ordinal positions.
  • Press Ctrl + 1.

Formatting Text Values as Superscripts to Write 1st 2nd 3rd in Excel

  • A window will pop up like the picture given below. Select the Superscript option.
  • Press OK.

Formatting Text Values as Superscripts to Write 1st 2nd 3rd in Excel

  • The cardinal position will be formatted correctly.
  • Drag the Fill Handle icon from the D5 cell to the D10 cell.

Formatting Text Values as Superscripts to Write 1st 2nd 3rd in Excel

  • Excel will show the corrected format of the positions.

Formatting Text Values as Superscripts to Write 1st 2nd 3rd in Excel


Method 2 – Adding Superscript to the Quick Access Toolbar

Steps:

  • Select the arrow icon on the main file ribbon.
  • Select the More Commands option from the drop-down.

Formatting Adding Superscripts to Quick Access Toolbar to Write 1st 2nd 3rd in Excel

  • Select the Quick Access Toolbar in the pop-up window.
  • Select the Superscript option.
  • Click on the Add button.

Formatting Adding Superscripts to Quick Access Toolbar to Write 1st 2nd 3rd in Excel

  • You will find the superscript option on the other side. Press OK.

Formatting Adding Superscripts to Quick Access Toolbar to Write 1st 2nd 3rd in Excel

  • You will find the Superscript option in the toolbar.

Formatting Adding Superscripts to Quick Access Toolbar to Write 1st 2nd 3rd in Excel

  • Select the string in the D5 cell that you need to put into superscript (“st”).
  • Click on the Superscript option.

Formatting Adding Superscripts to Quick Access Toolbar to Write 1st 2nd 3rd in Excel

  • Excel will format the ordinal properly.
  • Use the Fill Handle to copy down this command from the D5 to the D10 cell.

Formatting Adding Superscripts to Quick Access Toolbar to Write 1st 2nd 3rd in Excel

  • You will get the following results.

Formatting Adding Superscripts to Quick Access Toolbar to Write 1st 2nd 3rd in Excel

Read More: [Fixed!] Excel Superscript Not Working


Method 3 – Applying Superscript by Inserting an Equation

Let’s remove the text from the cells in the last column in the sample dataset, then fill it with proper values.

Inserting Equation to Write 1st 2nd 3rd in Excel

Steps:

  • Select the Insert tab from your toolbar.
  • Select the Symbols and Equations options.

  • In the equation tab, you will find Structures. Click on it.
  • Select the script option and click on the first option.

Inserting Equation to Write 1st 2nd 3rd in Excel

  • You will find the equation writing expression.
  • Write down the ordinal numbers.

Inserting Equation to Write 1st 2nd 3rd in Excel

  • You will find the ordinal rank in cell D5.

Inserting Equation to Write 1st 2nd 3rd in Excel

  • Write down all the positions manually.


How to Write 1st 2nd 3rd in Excel Using VBA

Steps:

  • Press Alt+F11 to open the VBA window.
  • Click on Insert and select Module.

  • Copy the following code to the module:
Function OrdRank(s_Number As String) As String
Select Case CLng(VBA.Right(s_Number, 1))
Case 1
OrdRank = s_Number & "st"
Case 2
OrdRank = s_Number & "nd"
Case 3
OrdRank = s_Number & "rd"
Case Else
OrdRank = s_Number & "th"
End Select
Select Case VBA.CLng(VBA.Right(s_Number, 2))
Case 11, 12, 13
OrdRank = s_Number & "th"
End Select
End Function

Here, we declared some variables in the VBA code to build a user-defined function called OrdRank and used the Case Statement to apply some conditions.

  • Save the module and exit the window.
  • Select the E5 cell.

  • Copy the following formula in the selected cell:
=OrdRank(D5)

  • Press Enter
  • Copy the formula to the other cells with AutoFill.

  • Excel will show all the ordinal ranks in the D column.


Download Practice Workbook


Back to Learn Excel > Formatting Text > Subscript and Superscript


Related Articles


<< Go Back to Subscript and Superscript | Text Formatting | Learn Excel

Get FREE Advanced Excel Exercises with Solutions!
Souptik Roy
Souptik Roy

Souptik Roy, a BSc graduate in Naval Architecture and Marine Engineering from Bangladesh University of Engineering and Technology, dedicated 1.5 years to the ExcelDemy project. During this time, he authored 50+ articles and reviewed 20+ for ExcelDemy. Presently, he is a designer and content developer at YouHaveGotThisMath and Brainor, sister concerns of ExcelDemy. His educational content spans science, mathematics, and grammar. Roy's interests include developing creative ideas, visualizing concepts with tools like Adobe Illustrator, and problem-solving within Microsoft... Read Full Bio

We will be happy to hear your thoughts

Leave a reply

Advanced Excel Exercises with Solutions PDF

 

 

ExcelDemy
Logo