Header and footer in Excel: how to insert, edit and remove

Do you want to know how to make a header in Excel? Or are you wondering how to add the footer page 1 to the current worksheet? This tutorial will teach you how to quickly insert one of the predefined headers and footers and how to create a custom one with your own text and graphics.

To make your printed Excel documents look more stylish and professional, you can include a header or footer on each page of your worksheet. Generally, headers and footers contain basic information about the spreadsheet such as page number, current date, workbook name, file path, etc. Microsoft Excel provides a handful of predefined headers and footers to choose from, as well as allows creating your own ones.

Headers and footers are displayed only on printed pages, in Print Preview and Page Layout view. In the normal worksheet view, they are not visible.

How to add header in Excel

Inserting a header in an Excel worksheet is quite easy. Here's what you do:

  1. Go to the Insert tab > Text group and click the Header & Footer button. This will switch the worksheet to Page Layout view.
    Adding a header in Excel
  2. Now, you can type text, insert a picture, add a preset header or specific elements in any of the three Header boxes at the top of the page. By default, the central box is selected:
    Type text or insert a built-in element in the header box.

    If you wish the header to appear in the top left or top right corner of the page, click the left or right box and enter some information there.

  3. When finished, click anywhere in the worksheet to leave the header area. To exit the header box without keeping the changes, press Esc.

When you print out your worksheet, the header will be repeated on each page.

Like an Excel header, a footer can also be inserted in a few easy steps:

  1. On the Insert tab, in the Text group and click the Header & Footer button.
  2. On the Design tab, click Go to Footer or scroll down to the footer boxes at the bottom of the page.
    Inserting a footer in Excel
  3. Depending on the desired location, click the left, center, or right footer box, and type some text or insert the element you want. To add a preset footer, please follow these steps, to make a custom Excel footer, see these guidelines.
  4. When done, click anywhere in the worksheet to exit the footer area.

For example, to insert page numbers at the bottom of the worksheet, select one of the footer boxes and click Page Number on the Design tab, in the Header & Footer group.
Add the footer page 1, page 2, etc.

Microsoft Excel comes equipped with a number of inbuilt headers and footers that can be inserted in your document in a mouse click. Here's how:

  1. On the Insert tab, in the Text group, click Header & Footer. This will display the worksheet in Page Layout view and get the Design tab to appear.
  2. On the Design tab, in the Header & Footer group, click the Header or Footer button, and select the built-in header or footer of your choosing.

As an example, let's insert a footer that displays a page number and file name:
Inserting a footer in Excel that displays a page number and file name

Voila, our Excel footer is created, and the following information will be printed at the bottom of each page:
A predefined Excel footer is added.

Two things you should know about preset headers and footers

When inserting an inbuilt header or footer in Excel, please be aware of the following caveats.

1. Preset headers and footers are dynamic

Most of the preset headers and footers in Excel are entered as codes, which makes them dynamic - meaning your header or footer will change to reflect the latest changes you make to the worksheet.

For example, the code &[Page] inserts different page numbers on each page and &[File] displays the current file name. To see the codes, just click the corresponding header or footer text box. If you have chosen to add a complex header or footer, chances are that different elements will be inserted in different boxes like in the above example:
Different header/footer elements are inserted in different boxes.

2. Preset headers and footers are inserted in predefined boxes

When adding a built-in header or footer, you cannot control the location of specific elements - they are inserted in the predefined boxes no matter which box (left, center, or right) is currently selected. To position the header or footer the way you want, you can move the inserted elements to other boxes by copying / pasting their codes or add each element individually as explained in the next section.

How to make a custom header or footer in Excel

In Excel worksheets, not only can you add preset headers and footers, but also make your own ones with custom text and images.

As usual, you start by clicking the Header & Footer button on the Insert tab. Then, click one of the boxes at the top (header) or at the bottom (footer) of the worksheet and type your text there. You can also enter different pieces of information by selecting one of the built-in elements on the Design tab, in the Header & Footer Elements group.

This example will show you how to create a custom header with your company logo, page numbers, file name and current date.

  1. To begin with, let's insert File Name (workbook name) in the central header box:
    Insert the workbook name in the central header box.
  2. Then, select the right box and insert Page Number there. As you can see in the screenshot below, this only displays the number:
    Insert the page number in the right header box.

    If you want the word "Page" to appear as well, click anywhere in the right text box, and type "Page" in front of the code, separating the word and the code with a space character like this:
    Type your own text before the code in a header box.

  3. Additionally, you can insert the Number of Pages element in the same box by clicking on the corresponding button on the ribbon, and then type "of" in between the codes so that your Excel header displays something like "Page 1 of 3":
    Insert the Number of Pages element in an Excel header.
  4. Finally, let's insert the company logo in the left box. For this, click the Picture button, browse for the image file, and click Insert. The &[Picture] code will be inserted in the header straight away:

Insert a picture in a header.

As soon as you click anywhere outside the header box, an actual picture will show up.

Our custom Excel header looks pretty nice, don't you think?
Custom Excel header with text and image

Tips:

  • To start a new line in a header or footer box, press the Enter key.
  • To include an ampersand (&) in the text, type two ampersand characters without spaces. For example, to include Products & Services in the header or footer, you type Products && Services.
  • To add page numbers to Excel headers and footers, insert the &[Page] code in combination with any text you want. For this, use the built-in Page Number element or one of the preset headers and footers. If you enter the numbers manually, you will end up having the same number on each page.

Add headers and footers using the Page Setup dialog box

If case you'd like to create a header or footer for chart sheets or for several worksheets at a time, the Page Setup dialog box is your option.

  1. Select one or more worksheets for which you'd like to make a header or footer. To select multiple sheets, hold down the Ctrl key while clicking the sheet tabs.
  2. Go to the Page Layout tab > Page Setup group and click the Dialog Box Launcher.
    On the Page Layout tab, in the Page Setup group, click the Dialog Box Launcher.
  3. The Page Setup dialog box will show up where you can select one of the preset headers and footers or make your own one.

To insert a preset one, click the drop-down arrow in the Header or Footer box and choose from the available options. For example:
Inserting a preset footer

To create a custom header or footer, do the following:

  • Click the Custom Header… or Custom Footer… button.
  • Select the left, center or right section box, and then click one of the buttons above the sections. To find out exactly what element a particular button inserts, hover over it to display a tooltip.
    For example, this is how you can add a page number to the right hand side of your Excel header:
    Add a page number to the right hand side of an Excel header.
    You can also type your own text in any section as well as edit or remove the existing text or codes.
  • When finished, click OK.

Tip. To see how your header or footer will look like on a printed page, click the Print Preview button.

There are two ways to edit headers and footers in Excel - in Page Layout view and by using Page Setup dialog.

Change header or footer in Page Layout view

To switch to Page Layout view, go to the View tab > Workbook Views group, and click Page Layout.
Switch to Page Layout view in Excel.

Or, click the Page Layout button on the status bar in the bottom-right corner of the worksheet:
The Page Layout button on Excel's status bar

Now, you select the header or footer text box and make the desired changes.

Change header or footer in the Page Setup dialog

Another way to modify an Excel footer or header is by using the Page Setup dialog box. Please remember that a header and footer of chart sheets can only be edited in this way.

Once you have finished creating or editing your Excel footer or header, how do you get out of the header and footer view and return to the regular view? By doing any of the following:

On the View tab > Workbook Views group, click Normal.
Closing header and footer in Excel

Or, just click the Normal button on the status bar.
Return to Normal view.

To remove an individual header or footer, simply switch to Page Layout view, click the header or footer text box, and press the Delete or Backspace key.

To delete headers and footers from multiple worksheets at once, carry out these steps:

  1. Select the worksheets from which you want to remove a header or footer.
  2. Open the Page Setup dialog box (Page Layout tab > Page Setup group > Dialog Box Launcher).
  3. In the Page Setup dialog box, click the drop-down arrow to open the list of preset headers or footers, and select (none).
  4. Click OK to close the dialog box.

Removing headers and footers from multiple worksheets at a time

That's it! All headers and footers in the selected sheets will be removed.

Now that you know the essentials of Excel headers and footers, the below tips may help you avoid common challenges.

How to add header and footer to all or selected sheets in Excel

To insert headers or footers on multiple worksheets at a time, select all target sheets, and then add a header or footer in the usual way.

  • To select multiple adjacent worksheet, click the tab of the first sheet, hold down the Shift key, and click the tab of the last sheet.
  • To select multiple non-adjacent sheets, hold down the Ctrl key while clicking the sheet tabs individually.
  • To select all worksheets, right-click any sheet tab, and choose Select All Sheets from the context menu.

Once the worksheets are selected, go to the Insert tab > Text group > Header & Footer and enter the header or footer information as you like. Or insert a header/footer via the Page Setup dialog.

When finished, right click any unselected sheet to ungroup the worksheets. If all of the sheets are selected, click any sheet tab, and then click Ungroup Sheets in the context menu.

How to format text in Excel header and footer

To quickly change the font style or font color of your header or footer, select the text and pick the desired formatting option in the pop-up window:
Formatting text in an Excel header and footer

Alternatively, select the header or footer text you want to change, head to the Home tab > Font group and select the formatting options you want.

How to make a different header or footer for the first page

If you'd like to insert a specific header or footer on the first page of your worksheet, you can have it done in this way:

  1. Change to Page Layout view.
  2. Select the header or footer.
  3. Go to the Design tab, and check the Different First Page box.
  4. Set up a special header or footer for the first page.

Creating a different header or footer for the first page

Tip. If you want to create separate headers or footers for odd and even pages, select the Different Odd & Even Pages box, and enter different information on page 1 and page 2.

How avoid resizing the header / footer text when scaling the worksheet for printing

To keep the font size of the header or footer text intact when the worksheet is scaled for printing, switch to Page Layout view, select the header or footer, go to the Design tab and clear the Scale with Document box.
Avoid resizing the header / footer text when scaling the worksheet for printing

If you leave this checkbox selected, the header and footer font will scale with the worksheet. For example, the header text will become smaller when you select the Fit Sheet on One Page printing option.

That's how you add, change and remove headers and footers in Excel. I thank you for reading and hope to see you on our blog next week.

40 comments

  1. I have an excel workbook with 6 worksheets labeled (Summary, A, B, C, D & E). Summary sheet as 2 pages, A has 1 page, B has 1 page, C has 5 pages, D has 3 pages, E has 6 pages. If I print the active worksheet for "Summary" I get Page 1 of 2 and 2 of 2, but if I print Entire Workbook, I get Page 1 of 18 and 2 of 18.

    Is there a way to insert a footer that says "Page &[Page] of &[WorkSheetPages]" instead of "Page &[Page] of &[Pages]". This way when I print the entire workbook my footer would show:

    Schedule Summary
    Page 1 of 2 - 2 of 2

    Schedule A
    Page 1 of 1

    Schedule B
    Page 1 of 1

    Schedule C
    Page 1 of 5 - 5 of 5

    Schedule D
    Page 1 of 3 - 3 of 3

    Schedule E
    Page 1 of 6 - 6 of 6

    I can print each worksheet separately and accomplish this but if printing the entire workbook it always counts all pages and I get 1 of 18 and so one. Same thing if exporting to PDF but then I have to combine 6 separate pdf's into one to accomplish this.

    Hope this makes sense.

    Jim

    • Hi Jim, did you find a solution for your question, I have the same issue and would like to solve it, thanks

  2. it was usefull

  3. How to handle if last page use complex header/footer image but all other page use simple header image?

  4. I don't know why my point isn't being made. Maybe a picture will help. Except I don't know how to paste a 'snip & sketch' image here or upload one to this post.

    Let me try, again.

    If you could see my picture, you would see the right most character of my heading (the 1 in the page #) is about 1 inch from the right most edge of the page. While the > symbol is about 1/2 inch from the right most edge of the page. How do I get the page number to scoot over to the right another 1/2 inch?

    My margins are as follows: Top:0, Bottom: 6, Left: 0.25, Right: 0, Header: 0.075, Footer: 0. Yes the bottom margin is very large, for a reason. But that shouldn't affect the horizontal printing.

    The option 'align with page margins' is checked. If I uncheck it, the heading text gets worse. It ends about 2 inches from the right edge of the page.

    Is there anything else I can say or do to convey my question?

    Thank you.

  5. I am using Excel and i have a header set up. Can i make the footer exactly the same as the header and each time i edit the header it will update it in the footer?

    I use the sheet(s), update them each time i need to use them, and then print that sheet off.

    It would be useful to me to make each header and footer the same. for instance, my header says "segmentation job 1" and next time i use it i would change the header to "segmentation job 2" and i would like the footer to say that and each time i change the job number in the header it will change it in the footer?

  6. The question was how to change header and footer in Excel Mobile. This only works for Desktop.

  7. Hello! I have touched the problem recently, is it possible to change Header for all sheets without changing landscape pages. Every time, when I change the header for all sheets in new workbook, automatically pages are oriented vertical. But I have in one workbook both orientation. Is there any solution, not to change manually page orientation after I change the header information!
    Thank You!

  8. Can we have a specific cell to appear as a headers instead of changing every single print out

  9. Hello,

    I want to make an excel with multiple sheets. On the first sheet i will put some general information: project name, project number, etc.
    Now i wont to make a header for all sheets. I want to have in header some informations from sheet 1 like project number, name, etc introduced before.
    The problem is i don't know how to do it. Please help!

  10. Is there anyway that when opening and saving a new file, that the file can automatically have a header or footer with the file name, and tab?

    I tend to create files, but then loose them cos I don't know where I've filed it!??

  11. The Normal Workbook View is grayed out. Am I stuck in Header & Footer? I am using Microsoft 365

    • I closed the file. Upon reopening it, I found that I was still in Header & Footer mode, but I could return to Normal view.

  12. HI..
    I have setup a header with my company letterhead jpeg file. When I share by email or save in a transfer folder, the other parties cannot open the working files with the letterhead appearing.

    please advice, thanks in advance.

  13. I still use Excell 12.3.6
    How can I remove a header from a second sheet?

  14. Thank you so much - sorted my adding header and footer issue - trick was go to "normal view" with the icon near the scale bar. GooglSearch - e Frustration gone in a moment!

  15. Please help me....
    I have placed the header in
    Sheet 1 same header
    Sheet 2 same header
    Sheet 3 same header but different on 1st page (do not want to show)
    When I select all sheets, it shows the same header on sheet 3 1st page too. Why and how to remove it.

  16. please I am a new person Excel VBA macros, I need a tutorials on how to write and create VBA macros in excel
    Thank you
    Best Regards

  17. My footer will not delete. I select none and hit the save button but still comes back. How do i get rid of it permamanetly

  18. Am NOT able to delete a header or footer from a spread sheet. Nothing you post above works.

  19. The size of printing in custom header is too small.
    How do I make it larger?

  20. Why is my footer covered up by the content of the spreadsheet?
    When I go to print I can't see it except a few words outside the margins of the actual cells.
    Thanks!

  21. Just thanks. This was a clear explanation and solved my problem.

  22. You don't explain here how to add formulas and this is the main question here. Bad response

  23. Hi,

    i would like to know how to amend an exiting date in header which is copied fromt he system and exported to excell

    e.g: date is Aug 20, xxxx i want to change to Sep 10, xxxx

  24. I need to justify left the text in the right header using VBA. Below is hte current code I have for the right header.
    wks.PageSetup.RightHeader = "&R" & "DocID: " & DocProperty("##ID##") & " Version: " & DocProperty("##REVISION##")

  25. There is NOT a way to EDIT a footer, like in Word. I do NOT want to create a new footer each time I change the Rev.date. old versions worked well. It is a shame that "software writers" like to show how complicated they can make a system work (or not work). Someone help me "EDIT" a footer.

  26. Hello,
    I received an excel document when open it shows the file name OVERHAUL-ebc. The main file name is actually OVERHAUL, but I want to get rid of ebc cause this is the author's name or signature. Also it is affecting my other new open excel docs whereby it appears Book4-ebc.
    Hoping you can help.
    Thank you.
    bonjing

  27. how do i insert a space between 2 footers in exce

  28. How To Add Text Above The Bottom Line in The Rightmost Footer Box

    Have you noticed that the text in the last footer text box is right adjusted AND at the bottom of the text box? Usually, this is what you want. For example, it is a great place to insert the "file name" when you are creating and printing multiple drafts of a spreadsheet.

    But sometimes, you want to insert text above the bottom line. There is a simple solution. Use Alt+Enter to insert a new line character in front of the text on the bottom line. This inserts a new line ABOVE the bottom line.

    If you want to use this trick, be sure to save your spreadsheet before you do. It is easy to mess up the format of the footer, and the easiest way to fix it is to exit the spreadsheet and load a new copy.

    Deacon John

  29. Is there any way to purge the drop-down list containing previous footer history? I want to delete confidential info that was included in a prior footer. Thanks!

  30. Is there a way to change the picture dependant on a cell selection.
    The scenario we have employees select the brand/ customer they are working on from a drop cell, and it changes the picture in the footer.
    Right now we have to have multiple variants of the same spreadsheet which is tedious.

  31. I have gone through the article on Header and Footer. This is rather applicable to PC, etc. What about Android mobile device? I shall be pleased to receive guidance from you.

  32. do How do change the back ground of th the cell

  33. How to add more than 3 columns in the predefined Header and footer section?

  34. How do I display both the current date and the date of one week ago in the header?

  35. nice post

  36. thanks svetlana

Post a comment



Thank you for your comment!
When posting a question, please be very clear and concise. This will help us provide a quick and relevant solution to
your query. We cannot guarantee that we will answer every question, but we'll do our best :)