How to add text to the beginning or end of all cells in Excel?

Sometimes you may need to add same specific text to the beginning or end of all cells in a selection. If you added the text to each cell manually one by one, it must be time-consuming. Are there easier ways? Yes, there are many easy tricks to add same text to the beginning or end of all cells in a selection.

Add specified text to the beginning / end of all cells with formulas

Add specified text to the beginning / end of all cells with VBA

Add specified text to the beginning / end of all ells with Kutools for Excel

Add specified text to the specified position of all cells with Kutools for Excel

Recommended Productivity Software

Office Tab: Use tabbed interface in Office as the use of web browser Chrome, Firefox and Internet Explorer.
Kutools for Excel: Adds 120 powerful new features to Excel. Increase your productivity in 5 minutes. Save two hours every day!
Classic Menu for Office: Brings back your familiar menus to Office 2007, 2010 and 2013 (includes Office 365).

Suppose you have a name roll as following screenshot shows, and the follow methods will guide you add specified text at the beginning and end of each cell in A1:C5.


arrow blue right bubble Add specified text to the beginning / end of all cells with formulas

There are two formulas to add specified text to the beginning or end of all selected cells in Microsoft Excel.

Method 1: & formula

Enter the ="Class A: "&A1 in Cell E1, and copy this formula to other cells with dragging the bottom right corner of the Cell E1.

Method 2: Concatenate formula

Enter the =Concatenate ("Class A: ", A1) in Cell E1, and copy this formula to other cells with with dragging the bottom right corner of the Cell E1.

Notes

1. If you want to add specified text in each cell, just replace the Class A: with your text in both formulas.

2. The formulas of =A1 & "Class A: " and =Concatenate (A1, "Class A: ") will add Class A: at the end of Cell A1.

3. Both formulas will not modify the contents in selection directly.


arrow blue right bubble Add specified text to the beginning / end of all cells with VBA

If you want to add specified text in each cells of a selection directly, the following VBA Macro will ease your work.

Step 1: Select the range in which you will add specified text;

Step 2: Hold down the Alt + F11 keys in Excel, and it opens the Microsoft Visual Basic for Applications window.

Step 3: Click Insert > Module, and paste the following VBA code in the Module Window.

VBA for adding specified text at the beginning of each cell

Sub AppendToExistingOnLeft()
Dim c As Range
For Each c In Selection
If c.Value <> "" Then c.Value = "LSB " & c.Value
Next
End Sub

VBA for adding specified text at the end of each cell

Sub AppendToExistingOnRight()
Dim c as range
For each c in Selection
If c.value <> "" Then c.value = c.value & " LSB"
Next
End Sub

you can change the variable "LSB" of the above codeas.

Step 4: Press the F5 key to run this macro. And all of the cells will be added the value LSB before or after the cell contents.


arrow blue right bubble Add specified text to the beginning / end of all cells with Kutools for Excel

Kutools for Excel's Add Text tool will help you quickly add specified text to the beginning or end of each cell in a selection.

Kutools for Excel includes more than 120 handy Excel tools. Free to try with no limitation in 30 days. Get it Now.

Step 1: Select the range in which you will add specified text.

Step 2: Click the Kutools > Text Tools > Add Text…. See screenshot:

doc-add-text-4

Step 3: In Add Text dialog box, enter the specified text in the Text box, and check the right option in Position section, such as Before first character, After last character, etc.

Step 4: Click OK or Apply. The specified value will be added before or after the cell contents. See screenshots:

Add the specific text before the cell contents
doc-add-text6
Add the specific text after the cell contents
doc-add-text7

Notes:

1. Kutools for Excel's Add Text tool allows you to preview the changes in selection in Preview section.

2. If you check the Skip non-text cells option, this tool won't add the specified text in cells with non-text content.


arrow blue right bubble Add specified text to the specified position of all cells with Kutools for Excel

Applying Kutools for Excel's Add Text function, you can not only add the specified text to the beginning or end of the cells, but also you can add the specified text to the specified position of the cells.

Step 1. Select a range you want to add text to.

Step 2. Click Kutools > Text Tools > Add Text, see screenshot:

Step 3. The Add Text dialog will be displayed, and enter the specified text and specify the certain position which you want to insert the text in the boxes. See screenshot:

Step 4. Click Ok or Apply. The specified text has been added to the specified position of the cells. See screenshot:

Please click here to know more about this Add Text feature.


Relative articles:


Is your problem solved?

Recommended Productivity Tools

The following tools will greatly save your time and effort, which one do you prefer?
Office Tab: Using handy tabs in your Office, as the way of Chrome, Firefox and New Internet Explorer.
Kutools for Excel: 120 powerful new functions for Excel, Increase your productivity in 5 minutes. Save two hours every day!
Classic Menu for Office: Bring back familiar menus to Office 2007, 2010, 2013 and 365, as if it were Office 2000 and 2003.

Kutools for Excel

gold star1 Amazing! Increase your productivity in 5 minutes. Don't need any special skills, save two hours every day!

gold star1 More than 120 powerful advanced functions which designed for Excel:

  • Merge Cell/Rows/Columns without Losing Data.
  • Combine and Consolidate Multiple Sheets and Workbooks.
  • Compare Ranges, Copy Multiple Ranges, Convert Text to Date, Unit and Currency Conversion.
  • Count by Colors, Paging Subtotals, Advanced Sort and Super Filter,
  • More Select/Insert/Delete/Text/Format/Link/Comment/Workbooks/Worksheets Tools...

Screen shot of Kutools for Excel

btn read more     btn download     btn purchase