Merge Cells in Excel Using Keyboard Shortcuts on Windows

How-to basics · Updated November 20, 2026

To merge cells in Excel for Microsoft 365 on Windows using only the keyboard, select the range and press Alt, H, M, then M. The letters are pressed one after another, not together. This merges the selected cells while keeping the value in the upper-left cell, so check the range first if it contains data.

Merging makes a group of adjacent cells behave like one larger cell, which is useful for a heading spanning several columns. It changes the worksheet layout rather than combining the contents of the cells. The steps below explain how to select a range, choose the right merge command, and reverse the change if needed.

What You’ll Need

  • Excel for Microsoft 365 on a Windows computer, with the workbook open and the worksheet you want to edit selected.
  • A rectangular range of adjacent cells to merge. Decide which cell’s content to keep; Excel retains the value in the range’s upper-left cell.
  • Permission to edit the worksheet. If the sheet is protected or the cells are in an Excel table, merging may be unavailable until you address that restriction.

Step-by-Step

  1. Choose the cells you want to merge. Click the upper-left cell of the intended range. To select with the keyboard, hold Shift and use the arrow keys to extend the selection. For example, to select A1:C1, start in A1 and press Shift+Right Arrow twice. The selected cells should be adjacent and form a rectangle; Excel cannot merge a scattered selection as one range. You can also press Ctrl+G, type a range such as A1:C1 in the Go To box, and press Enter.
  2. Check the selected range and its contents. Confirm that the selection includes exactly the cells you intend to combine. If several cells contain text, numbers, or formulas, copy anything you need to keep elsewhere before merging. Excel displays a warning when other cells contain data, but the safest approach is to decide what to preserve before continuing.
  3. Open the Home tab’s merge commands with Key Tips. Press and release Alt, then press H to open the Home tab’s Key Tips, followed by M for the Merge & Center menu. Do not hold all the keys down at once. These letters are sequential ribbon commands; if the first key tip differs in your Excel setup, follow the letters displayed on screen.
  4. Choose the merge action you want. After Alt, H, M, press M again to choose Merge Cells. This combines the selected cells without centering the surviving content. To merge and center the content instead, press C after opening the menu. To merge each row of a multirow selection separately, choose Merge Across with A. The menu’s on-screen Key Tips are the best guide if your installation displays different letters.
  5. Review the result. The range will act as a single cell, and the original upper-left cell’s content will remain. With Merge Cells, that content keeps its existing horizontal alignment; Merge & Center also centers it. If the text is difficult to read, adjust alignment or column width after merging, rather than merging extra cells without checking the layout.
  6. Repeat for another range if needed. Select the next range and use the same sequence. Each separate group needs its own selection and merge command. Avoid selecting a large block that includes unrelated rows: Merge Across treats each row separately, while Merge Cells combines the full rectangular selection into one cell.
  7. Undo promptly if the result is wrong. Press Ctrl+Z to undo a recent merge. You can also select the merged cell, open the same Home-tab menu with Alt, H, M, and choose Unmerge Cells with U. Unmerging restores the cell boundaries, but it does not bring back values discarded during the merge.

To merge and center with the Windows ribbon sequence, the full command is Alt, H, M, C. To merge cells without centering, it is Alt, H, M, M. Since merge choices are easy to confuse, pause at the menu and check the command labels if you are unsure which action a key tip will select.

Common Mistakes

  • Expecting Excel to combine every cell’s text. A merge does not concatenate the contents. Excel keeps the upper-left value and can discard values in the other selected cells. Copy or combine the information before merging if it all needs to appear in the result.
  • Using Merge & Center when you only want a merge. The Center command changes alignment as well as cell structure. If you do not want the text centered, choose Merge Cells instead and set alignment separately.
  • Merging an unnecessarily large range. A merged area can complicate selecting rows, sorting, filtering, and copying or pasting. Select only the cells needed for the heading or label, and avoid merging cells inside a data table.
  • Assuming Merge Across creates one large cell. Merge Across makes separate merged cells for each row in the selected range. For a single heading spanning columns across one row, select only that row before choosing a merge option.
  • Trying to merge cells in an Excel table. Excel does not allow merged cells within a formatted table. Convert the table to a range or place the heading outside the table if merging is essential. Consider the effect on table features before converting.
  • Pressing the shortcut keys simultaneously. Ribbon Key Tips are a sequence: tap Alt, then the displayed letters in order. Holding Alt while typing the whole sequence may not activate the intended command.

Tips

  • Use the Name Box or Go To for exact ranges. When a range is large or hard to navigate to, use Ctrl+G and enter its address, such as B2:E2. This reduces the risk of including an extra row or column by mistake.
  • Consider an alternative for headings. Merged cells can interfere with data operations. If you mainly want a heading centered over several columns, select the cells, open Format Cells with Ctrl+1, choose the Alignment tab, and set Horizontal to Center Across Selection if that option is available. This centers the text across the selection without merging the cells.
  • Use Merge Across for a repeated row layout. If each row needs its own merged label across several columns, select the rectangular block and choose Merge Across. Check the result row by row, because each row’s leftmost cell supplies that row’s content.
  • Keep headings separate from sortable records. A merged title above a table is usually safer than merged cells within the table’s records. This helps preserve predictable sorting, filtering, and copy-and-paste behavior.
  • On a Mac, do not assume the Windows sequence applies. Excel for Mac uses different keyboard conventions, and the Windows Alt Key Tip sequence may not work as written. Select the cells, use the Home tab’s Merge & Center control and its menu, or use Excel’s keyboard navigation to reach that ribbon command. Follow the on-screen labels in your version.
  • In Excel for the web, check the ribbon and browser behavior. Keyboard shortcuts can be affected by the browser or web app. Use the Home tab’s merge control if the Windows Key Tip sequence is intercepted or does not match the labels shown.

Troubleshooting

The sequence does nothing. Make sure the worksheet, rather than a text box or another application area, has focus. Tap Alt and look for Key Tips, then follow the letters shown. If you are on a Mac or in Excel for the web, use the ribbon control instead of assuming the Windows sequence is supported.

The merge command is unavailable. Check whether the selection is inside an Excel table, whether the sheet is protected, or whether the workbook is in a mode that prevents editing. If it is a table, consider converting it to a normal range using the Table Design tab’s Convert to Range command. If the sheet is protected, you may need the password or an authorized person to unprotect it.

Excel warns that merging keeps only the upper-left value. Cancel if you need content from other selected cells. Copy those values to another location first, or combine them in a separate cell before merging. If you proceed, inspect the result because the merge itself will not join the values.

The wrong cells were merged. Press Ctrl+Z immediately, then reselect the intended range and try again. If you have already made other changes, select the merged cell and choose Unmerge Cells from the Home tab menu. Unmerging restores the cell grid, not any overwritten or discarded contents.

The text is clipped or appears in the wrong place. Check the alignment, row height, column widths, and Wrap Text setting. A merge does not automatically make the text fit. Adjust the layout after confirming that the selected area and merge type are correct.

Frequently Asked Questions

What is the keyboard shortcut to merge cells in Excel?
On Windows, select the cells and press Alt, H, M, M in sequence. This opens the Home tab’s merge menu and chooses Merge Cells. Use the letters displayed as Key Tips if they differ in your setup.

How do I merge and center using the keyboard?
Select the range, then tap Alt, H, M, and C, one key after another. This merges the selection and centers its remaining content. The top-left cell supplies the value that remains.

Can I merge cells without losing data?
Not by using the merge command alone when multiple selected cells contain content. Excel retains the upper-left cell’s value, not a combined version of all entries. Copy or combine the other contents elsewhere before merging.

Can I undo a merge?
Yes. Press Ctrl+Z right after the action, or select the merged cell and choose Unmerge Cells from the Home tab’s Merge & Center menu. Unmerging restores separate cells but cannot recover discarded values.

Why can’t I merge cells in a table?
Excel does not support merged cells within a formatted table. Move the heading outside the table, or convert the table to a range if that fits your needs. Converting can affect table functionality, so consider whether sorting and filtering features are important first.

Does the same keyboard sequence work on Mac?
The Windows Alt Key Tip sequence is not the Mac equivalent. Use the Home tab’s merge control and follow the on-screen commands, or navigate the ribbon with the keyboard. Available shortcuts can vary with Excel version and settings.

Related

Try it: the Date Difference Calculator: days, months, years and weekdays between two dates, with the DATEDIF formulas.

More in How-to basics

Sources: Function behaviour and menu paths: Microsoft Support documentation for Excel. Method & sources

Spotted an error in this guide? Let us know.