How to Freeze a Row and Column in Excel at the Same Time

How-to basics · Updated November 3, 2026

How to Freeze a Row and Column in Excel at the Same Time

To freeze a row and a column together in Excel for Microsoft 365 on Windows, select the cell immediately below the row and immediately to the right of the column you want to keep visible, then choose View > Freeze Panes > Freeze Panes. For example, select B2 to keep the first row and first column visible while you scroll. This is useful when a long or wide worksheet has headings or identifiers that you need to see throughout your work.

Before you start, decide exactly which rows and columns should stay on screen. Excel freezes every row above the selected cell and every column to its left, so the cell you choose sets both boundaries at once. You can change the frozen area later by unfreezing the panes and selecting a different cell.

What You’ll Need

  • A workbook open in Excel, with the worksheet you want to work on selected.
  • A clear idea of which top rows and left-side columns should remain visible. For example, you might want row 1 for column headings and column A for item names.
  • Excel for Microsoft 365 on Windows for the menu paths below. Excel for Mac and Excel for the web have similar Freeze Panes commands; see the platform note in the steps.

Step-by-Step

  1. Open the correct worksheet and identify the boundaries. Click the sheet tab that contains the data. Note the last row you want to keep visible and the last column you want to keep visible. If you want only the top row and the first column to stay put, those boundaries are row 1 and column A. If you want rows 1 through 3 and columns A and B to remain visible, the boundaries are row 3 and column B. Being precise here prevents Excel from freezing more of the sheet than you intended.

  2. Work out the cell immediately below and to the right of those boundaries. For just row 1 and column A, the correct cell is B2. For rows 1 through 3 and columns A and B, select C4. The chosen cell itself is not frozen. Excel keeps the rows above it and the columns to its left in place, while the selected cell and the rest of the worksheet can scroll. This rule is the key to freezing a row and a column together.

  3. Select that cell. Click it in the worksheet grid, or use the Name Box to go directly to it. The Name Box is to the left of the formula bar; type the cell address, such as B2 or C4, and press Enter. If the worksheet is scrolled far down or across, going to the cell by address can be easier than finding it visually. Confirm the address before continuing, especially if you are freezing several rows or columns.

  4. Apply Freeze Panes. On the ribbon, click the View tab, then choose Freeze Panes in the Window group and choose Freeze Panes again from the menu. Use the first Freeze Panes command in the menu, not Freeze Top Row or Freeze First Column. The first command uses the selected cell to freeze both the rows above and the columns to the left. Excel will show a thin boundary line marking the frozen area.

  5. Check that both directions are frozen. Scroll down in the worksheet and confirm the chosen top rows remain visible. Then scroll to the right and confirm the chosen left columns remain visible. For the B2 example, row 1 should stay at the top and column A should stay at the left as you move through the data. You can test with the mouse wheel, scroll bars, or trackpad. If the frozen area is larger than you meant, use the troubleshooting steps below rather than trying to drag the boundary.

  6. Change the frozen area if necessary. First choose View > Freeze Panes > Unfreeze Panes. Then select the new boundary cell and repeat the Freeze Panes command. For example, if you initially froze B2 but later decide that rows 1 and 2 and column A should remain visible, unfreeze, select B3, and apply Freeze Panes again. Excel does not let you adjust an existing freeze simply by selecting a new cell; remove the current setting first.

  7. Use the corresponding command on Mac or the web. In Excel for Mac, select the boundary cell and use View > Freeze Panes > Freeze Panes; menu placement can vary slightly with the ribbon layout. In Excel for the web, select the cell and open the View tab, then use Freeze Panes and its Freeze Panes option. The same selection rule applies in both: choose the cell below the rows and right of the columns to keep visible. If your screen shows a simplified ribbon, expand the ribbon or look for the Freeze Panes command under View.

Common Mistakes

Selecting the row or column you want frozen instead of the cell after it. To keep row 1 and column A, select B2, not A1, A2, or B1. The selected cell defines the dividing point: everything above and left is frozen. If the wrong area is fixed, unfreeze and choose the correct boundary cell.

Choosing Freeze Top Row or Freeze First Column when you need both. Those menu options are convenient presets for a single edge of the sheet. To freeze a row and a column together, select the boundary cell and choose the main Freeze Panes option. For instance, B2 followed by Freeze Panes is the combined setup for row 1 and column A.

Assuming Excel freezes only the last row or column before the selection. It freezes all rows above the selected cell and all columns to its left. Selecting C5 therefore keeps rows 1 through 4 and columns A and B visible, not just row 4 and column B. That may cover a substantial part of the screen, so check how many rows and columns will be included before applying the command.

Trying to set a new boundary without clearing the old one. A worksheet has one Freeze Panes arrangement at a time. If a previous setup is active, unfreeze it first and apply the new boundary. Also, do not confuse freezing panes with splitting a worksheet into separately scrollable sections; split panes are a different view feature.

Tips

For a standard table with headings in row 1 and labels in column A, B2 is the fastest choice to remember. If there are two header rows and a single label column, choose B3. If your report uses four heading rows and the first two columns for identifiers, choose C5. In each case, move one row down and one column right from the bottom-right corner of the area you want fixed.

Keep the frozen area as small as practical. Freezing many rows or columns leaves less space for the scrollable data, particularly on a laptop screen. If your headings occupy several rows, consider whether all of them must remain visible or whether the main column labels alone are enough. A narrower frozen region makes it easier to compare entries across the worksheet.

Freeze Panes affects the current worksheet, not every sheet in the workbook. If several sheets need the same arrangement, apply the setting on each one separately. Before applying it to multiple sheets, make sure each sheet has the same layout; otherwise, the same cell address can freeze a different or unhelpful region. Save the workbook after arranging the view if you want to preserve your changes.

Frozen rows and columns stay visible as you scroll, but they do not change, lock, or protect the underlying cells. You can still edit their contents unless sheet protection or another workbook setting prevents editing. Likewise, freezing panes does not repeat print headings on printed pages. Use the separate print title settings if your goal is to repeat headings on paper or in a PDF.

Troubleshooting

The wrong rows or columns remain on screen. Choose View > Freeze Panes > Unfreeze Panes, inspect the intended boundaries, and select the cell one row below and one column to the right. Then choose Freeze Panes again. If you wanted row 1 and column A, for example, the cell must be B2. Avoid selecting the whole row or column as a substitute.

The Freeze Panes option is unavailable or does not behave as expected. Make sure you are working in the worksheet grid rather than editing text in a cell or a chart. In desktop Excel, switch to View > Normal if the sheet is in a view where the command is unavailable. Also check whether the workbook is in a restricted or shared state that limits editing, and whether you have selected the intended sheet.

Only one edge appears to stay fixed. Scroll in both directions to test the result; scrolling only down will show whether rows are frozen but will not confirm the columns. If horizontal scrolling is not available because the sheet fits on screen, widen the window or zoom out temporarily to test. If the setup still is not right, unfreeze it and repeat the combined selection method rather than applying a single-edge preset.

The boundary line is hard to see. Look for a thin line just below and to the right of the frozen area. The exact appearance may vary by platform and display scaling. Use a clear test by scrolling down and across; the behavior matters more than the line’s visibility. To return to a normal scrolling view, choose Unfreeze Panes from the View menu.

Frequently Asked Questions

Can I freeze the top row and first column at the same time?
Yes. Select B2, then choose View > Freeze Panes > Freeze Panes. Row 1 and column A will remain visible while you scroll.

How do I freeze two rows and one column?
Select B3, which is below rows 1 and 2 and to the right of column A. Then use the main Freeze Panes command. Excel freezes everything above and left of that cell.

Can I freeze a row that is not at the top?
You can keep a row visible by freezing all rows above the selected boundary, but you cannot freeze an isolated middle row while allowing the rows above it to scroll independently. For example, selecting A6 freezes rows 1 through 5, not only row 5.

Why does Freeze Top Row not keep my first column visible?
Freeze Top Row is a preset for the top row only. To hold a row and a column together, select the cell at their intersection boundary, such as B2 for row 1 and column A, then choose Freeze Panes.

Will frozen rows and columns appear on printed pages?
Not automatically. Freeze Panes controls the on-screen worksheet view. To repeat headings when printing, set print titles separately from the Page Layout tab; that setting is distinct from freezing panes.

Does freezing panes lock cells against editing?
No. It keeps rows and columns in view while scrolling, but it does not protect their contents. Use Excel’s sheet protection options if you need to restrict editing, and remember that protection is a separate feature.

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.