How to Put a Comma after 3 Digits in Excel (7 Useful Methods)

Below is a dataset showing 5 types of fruits a company sells throughout the year.

How to Put Comma after 3 Digits in Excel

Method 1 – Applying Custom Format 

Steps:

  • Right-click on cell C5.
  • Select Format Cells from the Context Menu.

Apply Custom Format to Put Comma after 3 Digits

  • Select Custom under Number in the new Format Cells dialogue box.

Apply Custom Format to Put Comma after 3 Digits

  • Enter any of the symbols below in the Type box and click OK:

###,###,###,###

00″,”000″,”000

#,##0.00

Apply Custom Format to Put Comma after 3 Digits

  • Here, the value in cell C5 now has a comma after 3 digits.

  • Follow the same procedure for the other cells.

OR

  • Right-click on cell C5 and select Format Painter.

  • Drag the brush icon over cell range C6:C9. The final output will look like this:

How to Put Comma after 3 Digits in Excel

Read More: How to Put Comma in Numbers in Excel


Method 2 – Using the Excel MID Function

Steps:

  • Select cell C5.
  • Enter the following formula:
=MID(C5,1,1)&","&MID(C5,2,2)&","&MID(C5,4,3)

Put Comma after 3 Digits with Excel MID Function

Here, the MID function extracts the comma for each value in the dataset, defining its location in the text string.

  • Press Enter. The result will look like this:

Put Comma after 3 Digits with Excel MID Function

  • Apply the same process to the cell range C6:C9.

Put Comma after 3 Digits with Excel MID Function

Read More: How to Put Comma After 2 Digits in Excel


Method 3 – Using the IF Function

Steps:

  • Select cell C5.
  • Enter the following formula:
=IF(LEN(C5)=6,REPLACE(C5,2,5,","&MID(C5,2,2))&","&MID(C5,4,3))

Use IF Function for Putting Comma after 3 Digits in Excel

  • Press Enter. The result will look like this:

Formula Breakdown

  • IF(LEN(C5)=6: Checks the condition with the LEN function to count the number of characters in the text string. The value here is 6.
  • REPLACE(C5,2,5): The REPLACE function replaces the numbers in a given text string in a certain location with another text string.
  • “&MID(C5,2,2))&”: it extracts the comma for each interval in the value.
  • Following the same process, you can put a comma after 3 digits in cell range C6:C9.

Use IF Function for Putting Comma after 3 Digits in Excel

Note: The values in the LEN and MID functions will vary according to the number of characters.

Read More: How to Put Comma After 5 Digits in Excel


Method 4 – Inserting TEXT Function 

Steps:

  • Select cell C5.
  • Enter the following formula:
=TEXT(C5,"00"",""000")

Insert TEXT Function to Insert Comma in Excel

Here, the intervals with 0 determine the location of each comma in the value. It will differ according to the number of characters in the text string.

  • Press Enter. The result will look like this:

  • Apply the same process in cell range C6:C9.

Insert TEXT Function to Insert Comma in Excel


Method 5 – Using Excel LEFT, MID & RIGHT Functions

Steps:

  • Select cell C5.
  • Enter the following formula:
=LEFT(C5,3)&","&RIGHT(C5,3)

Set Comma after 3 Digits with Excel LEFT, MID & RIGHT Functions

Here, the value has 6 digits. Therefore, we only used the LEFT and RIGHT functions to put a comma after every 3 digits from left to right. If the value has more than 6 digits, we will add the MID function to determine the intervals.

  • Press Enter. The results will look like this:

  • Apply the same procedure to cell range C6:C9.

Set Comma after 3 Digits with Excel LEFT, MID & RIGHT Functions


Method 6 – Using the Comma Style

Steps:

  • Select cell range C5:C9.

Put Comma after 3 Digits with Comma Style 

  • Go to the Home tab.
  • Click on the Comma Style from the Number group.

Put Comma after 3 Digits with Comma Style 

  • There will now be a comma after 3 digits in each cell value.

Put Comma after 3 Digits with Comma Style 

  • To increase or decrease the decimal point, click on the icons shown below:

  • The results will look like this:

Read More: How to Change Comma Style in Excel


Method 7 – Using Excel VBA 

Steps:

  • Select Visual Basic under the Code group in the Developer tab.

Use Excel VBA to Put Comma after 3 Digits

  • Select Module from the Insert section in the new window.

Use Excel VBA to Put Comma after 3 Digits

  • Enter the following code on the blank page:
Sub FormatNumberWithComma()
Range("D5") = Format(Range("C5"), "#,###")
Range("D6") = Format(Range("C6"), "#,###.00")
Range("D7") = Format(Range("C7"), "#,###")
Range("D8") = Format(Range("C8"), "#,##0.00")
Range("D9") = Format(Range("C9"), "#,###")
End Sub

Use Excel VBA to Put Comma after 3 Digits

  • Click on the Rub Sub button or press F5 on your keyboard.

  • Click on Run in the Macros window.

Use Excel VBA to Put Comma after 3 Digits

  • We have successfully inserted commas in all the values.

Use Excel VBA to Put Comma after 3 Digits

  • You can change or remove the decimal points by clicking the Decrease Decimal icon in the Home tab.


Things to Remember

  • While using any of the functions described above, make sure you put the positions of the intervals properly to get your desired result.
  • Thousand Separator might be a Comma (,) or a Full Stop (.) according to country region.
  • In the case of Custom Format, the selected cell will only be changed with a comma, not the entire worksheet.

Download the Practice Workbook

Download the workbook to practice.


Related Articles


<< Go Back to How to Add Comma in Excel | Concatenate Excel | Learn Excel

Get FREE Advanced Excel Exercises with Solutions!
Sanjida Mehrun Guria
Sanjida Mehrun Guria

Hello! Welcome to my blog. I have completed my Bachelor in Architecture from Ashanullah University of Science & Technology, Dhaka. I am a passionate, goal-oriented person with an immense thirst for knowledge and an attitude to grow continuously. Besides Architectural work, I find it very enthusiastic to work in Excel blogging. Exceldemy is a platform where I have got the opportunity to flourish my skill in Microsoft Excel and therefore, here I will be posting blogs related to... Read Full Bio

We will be happy to hear your thoughts

Leave a reply

Advanced Excel Exercises with Solutions PDF

 

 

ExcelDemy
Logo