The all border shortcut in Excel is Alt, H, B, A, pressed one after another. Select a table and press the sequence: every cell gets a thin line on all four sides, which makes printed sheets far easier to read.
Two true shortcuts also exist. Ctrl + Shift + 7 (the ampersand key) draws an outline around the selection only, and Ctrl + Shift + Minus removes all borders from it.
Quick facts
All borders
Alt, then H, then B, then AOutline only
Ctrl + Shift + 7Remove borders
Ctrl + Shift + MinusThick box
Alt, then H, then B, then TBottom border
Alt, then H, then B, then OMore options
Ctrl + 1, Border tab
All border shortcut in Excel and other border keys
| Border | Keys |
|---|---|
| All borders | Alt, then H, then B, then A |
| Outside borders | Ctrl + Shift + 7 |
| Thick outside border | Alt, then H, then B, then T |
| Bottom border | Alt, then H, then B, then O |
| Top border | Alt, then H, then B, then P |
| No border | Ctrl + Shift + Minus |
| Border tab with line styles | Ctrl + 1, then the Border tab |
After Alt, H, B, the border menu shows its own letters. Watch them for options such as double bottom border.
How to add all borders to a table
- Click inside the table and press Ctrl + A to select it.
- Press Alt, then H, then B, then A.
- Every cell now has thin black lines.
- Optionally press Alt, H, B, T to add a thick outline around the whole table.
To give another table the same borders, select it and press F4 to repeat the last border command.
Gridlines are not borders
The faint grey grid you see while working does not print by default. If a printed sheet looks like loose numbers with no lines, add borders, or tick Print gridlines under Page Layout, then Sheet Options. Borders give more control, such as thicker lines under headings and totals. The print preview shortcut lets you check before printing.
Format a table with one key instead
Ctrl + T turns data into an Excel table with banded rows, header styling and filters. Many people find that clearer than borders on every cell, and it updates automatically as rows are added. Choose a style from Table Design. Borders are still the better choice for forms, bills and printed registers.
When border shortcuts do not work
| Problem | Fix |
|---|---|
| Ctrl + Shift + 7 does nothing | Use the 7 on the top row, not the number pad |
| Ctrl + Shift + Minus changes language | Windows uses Ctrl + Shift for languages; change the hot key or use the ribbon |
| Borders missing in print | Line colour is white or very light; set it in the Border tab |
| Some inner lines missing | Use All borders, not Outside borders |
Borders on a Mac
Mac Excel shows no ribbon letters, so reach borders through the Borders button beside the font settings, or the Border tab in Format Cells. Shading cells is explained in fill colour shortcut, centred titles across columns in merge cells, and the remaining spreadsheet keys in our master Excel list.
Frequently asked questions
What is the all border shortcut in Excel?
What is the outline border shortcut?
How do I remove borders in Excel?
Why don't gridlines print?
Gridlines are for the screen. Add borders or tick Print gridlines.
How do I add a thick border around a table?
Is there a border shortcut in Excel for Mac?
Use the Borders button or Command + 1.