To insert a header in Excel, go to Insert > Header & Footer. Excel switches to Page Layout view and puts your cursor in the header. Type in the left, centre or right box, or use the Header & Footer tab to add page numbers, the date or the file name. Click any cell to finish.
- Click the worksheet you want to print.
- Go to Insert > Text > Header & Footer.
- Click the left, centre or right header box and type your text.
- To add a footer, click Go to Footer on the Header & Footer tab.
- Click any cell in the sheet, then choose View > Normal to go back to your usual view.
How do I add a header in Excel?
Use Insert > Header & Footer, then type into one of the three header sections. Each section is aligned differently: left, centre and right. Most reports put a title in the centre and a date or reference on the right.

When you click inside a header box, a contextual Header & Footer tab appears on the ribbon (older versions label it Design under Header & Footer Tools). From there you can:
- Pick a ready-made layout from the Header or Footer drop-down, such as "Page 1 of ?" or "Confidential, date, page".
- Insert live fields from the Header & Footer Elements group.
- Switch between top and bottom with Go to Header and Go to Footer.
Press Enter inside a box to start a new line. To show a single ampersand in your text, type two (&&), because Excel uses & to mark codes. Microsoft's article on headers and footers in a worksheet covers each option.
How do I add a footer in Excel?
A footer works exactly like a header, just at the bottom of the page. Go to Insert > Header & Footer, click Go to Footer, then type in the left, centre or right box. You can also scroll down to the bottom of the page in Page Layout view and click the "Add footer" area directly.
![Table of Excel header and footer codes: &[Page] prints 3, &[Pages] prints 12, plus &[Date], &[File], &[Tab] and &[Picture].](https://cdn.shopify.com/s/files/1/0707/4745/5702/files/header-footer-excel-2.jpg)
Header and footer fields are inserted as codes. You see the code while editing and the real value once you click away:
| Button | Code inserted | Prints as |
|---|---|---|
| Page Number | &[Page] | 3 |
| Number of Pages | &[Pages] | 12 |
| Current Date | &[Date] | Today's date |
| Current Time | &[Time] | The time you print |
| File Path | &[Path]&[File] | Full folder path and file name |
| File Name | &[File] | Budget 2026.xlsx |
| Sheet Name | &[Tab] | The worksheet tab name |
| Picture | &[Picture] | An inserted image or logo |
The date and time update every time you open or print the file. If you need a fixed date, type it as plain text instead.
How do I number pages in Excel?
Click in a header or footer box and choose Page Number on the Header & Footer tab. For "Page 3 of 12", click Page Number, type a space, the word "of" and another space, then click Number of Pages. The box will read Page &[Page] of &[Pages].
![Excel footer code Page &[Page] of &[Pages] explained: Page Number and Number of Pages buttons print as Page 3 of 12.](https://cdn.shopify.com/s/files/1/0707/4745/5702/files/header-footer-excel-3.jpg)
Two settings in Page Layout > Page Setup (click the small dialog launcher arrow in the corner of the group) control numbering:
- First page number on the Page tab: type a number such as 5 to start there. Type Auto to go back to the default.
- Different First Page on the Header/Footer tab (or in the Options group of the Header & Footer tab): hides the header and footer on page one, which suits a cover page.
To number several sheets at once, hold Ctrl and click each sheet tab, then open Page Setup > Header/Footer > Custom Footer and insert the page number there. Each sheet starts again at 1, so for continuous numbering set the second sheet's First page number to follow the first sheet's last page. Microsoft's guide to inserting page numbers on worksheets shows the same steps with screenshots.
What we commonly see: page numbers appear on screen but not on the printout, or the numbering jumps. Usually only one sheet in a multi-sheet print job has the footer. Group the sheets first (Ctrl+click their tabs), add the footer once, then right-click a tab and choose Ungroup Sheets so you do not accidentally type into every sheet.
How do I edit or remove a header in Excel?
To edit, go to Insert > Header & Footer (or View > Page Layout) and click the text you want to change. Type over it or use the element buttons. To remove a header, click its box, select the contents and press Delete.
To remove headers or footers from several sheets in one go, select the sheets, open Page Layout > Page Setup, go to the Header/Footer tab, and choose (none) in the Header box and the Footer box. Click OK.
Press Esc while editing if you want to leave the header without keeping your changes.
How do I freeze the header row in Excel?
A printed header is different from a header row you want to keep visible while scrolling. To lock row 1 on screen, go to View > Freeze Panes > Freeze Top Row. To lock more than one row, click the cell below the last row you want to keep (for example A3 to freeze rows 1 and 2), then choose View > Freeze Panes > Freeze Panes. Undo it with View > Freeze Panes > Unfreeze Panes.
To print your column headings at the top of every page, use print titles instead:
- Go to Page Layout > Print Titles.
- On the Sheet tab, click in Rows to repeat at top.
- Click the row number of your heading row, or type
$1:$1. - Click OK and check the result in File > Print.
Microsoft notes in its print titles article that the command is greyed out while you are editing a cell, when a chart is selected, or when several sheets are grouped. Our Excel tutorial for beginners explains the difference between a header row and a page header if you are new to this.
How do I add a watermark in Excel?
Excel has no Watermark button, but you can fake one with a picture in the header. Microsoft's watermark article describes the method:
- Go to Insert > Header & Footer and click the centre header box.
- On the Header & Footer tab, click Picture and choose an image, such as a "DRAFT" or "CONFIDENTIAL" graphic. The box shows
&[Picture]. - Click Format Picture. On the Picture tab, set Color to Washout so the image is faint behind the data.
- To move the watermark down the page, click before
&[Picture]and press Enter a few times.
The watermark shows only in Page Layout view, Print Preview and on paper or PDF, not in Normal view. To remove it, delete &[Picture] from the header.
Advanced nuance: a header or footer can hold up to 255 characters, and a very tall header (a big logo or many blank lines) pushes the data down the page. If your header overlaps the data, increase the top margin in Page Layout > Margins > Custom Margins, or untick Align with Page Margins in the Options group to adjust the layout.
Do headers and footers work the same in every Excel version?
Yes, for the essentials. Insert > Header & Footer, the element buttons and Page Setup work the same in Excel 2016, 2019, 2021, 2024 and Microsoft 365 on Windows. The only visible change is the tab name: newer builds show a Header & Footer tab, while older ones show Design. On a Mac, Insert > Header & Footer and the Page Layout tab offer the same codes; use Cmd instead of Ctrl to group sheets.
If you print reports often, desktop Excel, such as one of the editions in the Office 2024 collection, gives you the full Page Setup dialog. Keyboard users will find Page Layout view and other view switches in our Excel keyboard shortcuts guide.
Frequently asked questions
Why can't I see my header in Excel?
Headers and footers are hidden in Normal view, which is the view most people work in. Switch to View > Page Layout or open File > Print to see them. If they still do not appear, check that you added them to the sheet you are viewing, because each worksheet has its own header and footer settings.
Can I put a cell value in an Excel header?
Not with a built-in button. Header codes cover page numbers, dates, the file path, file name, sheet name and pictures, but they cannot read a cell. To show a cell's value, you need a short VBA macro that copies the cell into the header before printing, or you can type the value into the header by hand each time it changes.
How do I add a logo to the Excel header?
Click the header box where the logo should go, choose Picture on the Header & Footer tab, and pick the image file. Then click Format Picture and reduce the height and width on the Size tab so it does not push your data down. The logo prints on every page of that sheet.
How do I make a different header on the first page?
Click into the header, then tick Different First Page in the Options group of the Header & Footer tab. Page one now has its own header and footer boxes, which you can fill or leave blank. Tick Different Odd & Even Pages if you need mirrored headers for double-sided printing.
Why are my page numbers wrong when I print several sheets?
Each worksheet numbers its own pages, starting at 1, unless you change the First page number in Page Setup. When you print the whole workbook, set each later sheet to start at the right number, or print the workbook to PDF in one job and check the numbering before you send it.
Related guides
- Excel tutorial for beginners
- Excel keyboard shortcuts you will actually use
- How to insert, delete and move rows, columns and sheets
- Office 2016, 2019, 2021 and 2024 compared
Links in this guide
| Link | Type | Why it helps |
|---|---|---|
| Microsoft Support: Headers and footers in a worksheet | External | Official steps for every header and footer option |
| Microsoft Support: Insert page numbers on worksheets | External | Page X of Y and starting page numbers |
| Microsoft Support: Print rows with column headers on every page | External | Setting Rows to repeat at top |
| Microsoft Support: Add a watermark in Excel | External | The picture-in-header watermark method |
| Excel tutorial for beginners | Internal | Basics of rows, headings and views |
| Office 2024 licence keys | Internal | Desktop Excel editions with full Page Setup |
| Excel keyboard shortcuts | Internal | Faster view switching and printing |
| Insert, delete and move rows, columns and sheets | Internal | Managing the sheets you print |
| Office versions compared | Internal | Differences between Office releases |
