Excel Shortcut to Merge Cells (3 Methods + Bonus)

In Microsoft Excel, merging cells is one of those essential tasks. To prepare a great presentation, you may need to merge some cells of your dataset. Most of us combine cells using the quick access toolbar of Excel. But there’s more to it. In this tutorial, you will learn to use the Excel shortcut to merge cells. This tutorial will be on point with suitable examples and their proper illustrations.


Download Practice Workbook

Download practice workbook.


How to Merge Cells in Excel

In Microsoft Excel, we need to merge cells to create a great visual illustration. Sometimes, our given data doesn’t fit into the cells. So, we need to expand that to show. But if we expand the row or column, it extends the other data also.

Take a look at the following screenshot:

Merge Cells Using Excel Shortcut

Here, our title of the dataset is in Cell B2. In order to see in whole, we have to expand the column.

As you can see, we extended the column but it doesn’t look good. Also, look at column B. It extended the whole column. To fix this, we can use the Merge & Center command from the quick access toolbar.

Just select columns B, C, and D from row 2. And select Merge & Center from the Alignment group of the Home tab.

Merge Cells Using Excel Shortcut

Now, you can see the result after merging the cells.

Now, you can easily say, merging cells in Excel makes a great visual treat for the users. That’s why we need it.


3 Ways to Merge Cells Using Excel Shortcut

Now, we all know to merge cells in Excel with built-in commands. But in the following sections, you will learn the Excel shortcut to merge cells in Excel. It will save you a lot of time. We recommend you learn and implement all these methods in your Excel worksheet. Definitely, it will develop your Excel knowledge.


1. Excel Shortcut for Merge & Center

Now, if you want to merge multiple cells and want your data to align center, you can use this shortcut.

The shortcut we are using to merge cells:

Alt+H+M+C

It works similarly to the Merge & Center command of the quick access toolbar.

To demonstrate this, we are using the following dataset:

Merge Cells Using Excel Shortcut

Here, we have a dataset of some salespersons. We divided our dataset based on the products they sell. The salespersons under the green marker sell TV and yellow marker sell Computer. Now, our goal is to merge the cells of Column B. We want a single cell for TV and Computer.

📌 Steps

  • First, select the range of cells B5:B7.

Merge Cells Using Excel Shortcut

  • Then, press Alt+H+M+C. Press these buttons one by one.

Merge Cells Using Excel Shortcut

  • Again, select the range of cells B8:B10.

  • After that, press Alt+H+M+C.

Merge Cells Using Excel Shortcut

As you can see, we have successfully used the shortcut to merge the cells and align them into the center in Excel. And obviously, it is looking quite more impressive than before.

Note:

This Excel shortcut merges the cells in order that the merged cell has the content center aligned. But it doesn’t automatically change the vertical alignment.

Read More: Shortcut for Merge and Center in Excel (3 Examples)


2. Excel Shortcut to Merge Cells across Rows

The shortcut we are using:

Alt+H+M+A

This shortcut will merge cells across the columns. This is ideal if you merge cells of multiple columns. It won’t work on rows. Also, it will automatically make the cells left-aligned.

Take a look at the following dataset:

Here, our title is in Cell B2. Our goal is to merge this title with the cells C2 and D2.

📌 Steps

  • First, select the range of cells B2:D2.

Excel Shortcut to Merge Cells across Rows

  • Then, press Alt+H+M+A. Press these buttons one by one.

Excel Shortcut to Merge Cells across Rows

As you can see, we are successful to merge cells across columns using the Excel shortcut. And it is left-aligned. This shortcut will only work for columns.

Note:

If you choose cells in multiple rows, this shortcut will merge the cells for individual rows. All the cells from all the rows will not be merged into one single cell.

Read More: How to Combine Two Cells in Excel (6 Quick Methods)


3. Excel Shortcut to Merge Cells into One Cell

The Excel shortcut we are using here:

Alt+H+M+M

Now, you can use this shortcut to merge any number of rows and columns together.

Take a look at the following dataset:

Here, it is a simple dataset. We have two data here. Our goal is to merge multiple columns and rows to view these data in a single cell.

📌 Steps

  • First, select the range of cells B5:D7.

Excel Shortcut to Merge Cells into One Cell

  • Then, press Alt+H+M+M. Press these buttons one by one.

Excel Shortcut to Merge Cells into One Cell

  • Again, select the range of cells B8:D10.

  • After that, press Alt+H+M+M.

Excel Shortcut to Merge Cells into One Cell

As you can see, we are successful to merge cells in Excel with this shortcut. Notice here, we have merged three rows and three columns into a single cell.

Note:

If you choose cells from multiple rows, this shortcut will not work like the previous one, rather it will combine the cells into one and the vertical and horizontal alignment will be as before.

Read More: How to Combine Cells into One with Line Break in Excel (5 Methods)


Excel Shortcut to Effectively Undo the Merge Cells Commands

Now, you can to anytime to your unmerged state by pressing Alt+Z. But, if you get a new workbook from another source, it won’t work.

To unmerge these cells, we are going to use this Excel shortcut:

Alt+H+M+U

Here, to demonstrate this, we are using the previous dataset of merged cells:

Now, we are going to unmerge the cells of TV and Computer with the Excel shortcut.

📌 Steps

  • First, select the range of the cell of the TV.
  • Then, press Alt+H+M+U. Press these buttons one by one.

Excel Shortcut to Effectively Undo the Merge Cells Commands

  • Again, select the cell of the Computer.
  • After that, press Alt+H+M+U.

Excel Shortcut to Effectively Undo the Merge Cells Commands

As you can see, you can easily unmerge any number of cells using this Excel shortcut.


Create Custom Shortcut with VBA Macros to Merge and Center Cells

Now, this is a bonus technique. Basically, we are using Microsoft Excel’s VBA code to create a custom key. You may think this is a hectic process. But once you have done this, you can merge cells anywhere in your workbook. You can keep this method in your arsenal to develop your skills. Hopefully, it will come in handy in the future.

This VBA code will merge the cells and align them into a center similar to the first method. That’s why we are using the same dataset:

Create Custom Shortcut to Merge and Center Cells

📌 Steps

  • First, press Alt+F11 on your keyboard to open Visual Basic Application.
  • Then, select Insert > Module.

  • After that, type the following code:
Sub Merge_Cells()

With Selection
.HorizontalAlignment = xlCenter
.Merge
End With

End Sub
  • Now, save the file.
  • After that, press Alt+F8 to open the Macro dialog box.

  • Now, select Options.

Create Custom Shortcut to Merge and Center Cells

  • In the Macro option dialog box, give your desired key with the Ctrl. Here, we are giving “j” as a key. So, our shortcut will be Ctrl+j.
  • After that, click on Ok.
  • Now, select the range of cells B5:B7.

Create Custom Shortcut to Merge and Center Cells

  • Then, press Ctrl+j.

Create Custom Shortcut to Merge and Center Cells

  • Again, select the range of cells B8:B10.

  • After that, press Ctrl+j.

Create Custom Shortcut to Merge and Center Cells

As you can see, we have successfully created a custom shortcut key in Excel to merge cells. Now, using this shortcut, you can merge cells to the center anytime.

Read More: How to Combine Cells with Same Value in Excel (3 Easy Ways)


💬 Things to Remember

There is a big limitation of merging cells in Excel. If you have multiple data in multiple cells, Excel will only show the upper-left value after merging. So, if you don’t want to lose data, read this: How to Merge Cells in Excel with Data (3 Ways)

If you merge plain data, it will cause several problems. So, make sure before you merge cells.

After unmerging cells in Excel, it will have the format that you used before.

You can’t perform sorting or filtering on merged cells.

You can’t copy and paste data into merged cells.


Conclusion

To conclude, I hope this tutorial has provided you with a piece of useful knowledge to use the shortcut to merge cells in Excel. We recommend you learn and apply all these instructions to your dataset. Download the practice workbook and try these yourself. Also, feel free to give feedback in the comment section. Your valuable feedback keeps us motivated to create tutorials like this.

Don’t forget to check our website Exceldemy.com for various Excel-related problems and solutions.

Keep learning new methods and keep growing!


Related Articles

Get FREE Advanced Excel Exercises with Solutions!
A.N.M. Mohaimen Shanto
A.N.M. Mohaimen Shanto

A.N.M. Mohaimen Shanto, a B.Sc. in Computer Science and Engineering from Daffodil International University, boasts two years of experience as a Project Manager at Exceldemy. He authored 90+ articles and led teams as a Team Leader, meticulously reviewing over a thousand articles. Currently, he focuses on enhancing article quality. His passion lies in Excel VBA, Data Science, and SEO, where he enjoys simplifying complex ideas to facilitate learning and growth. His journey mirrors Exceldemy's dedication to excellence and... Read Full Bio

We will be happy to hear your thoughts

Leave a reply

Advanced Excel Exercises with Solutions PDF

 

 

ExcelDemy
Logo