Automatically number rows - Microsoft Support (2024)

Unlike other Microsoft 365 programs, Excel does not provide a button to number data automatically. But, you can easily add sequential numbers to rows of data by dragging the fill handle to fill a column with a series of numbers or by using the ROW function.

Tip:If you are looking for a more advanced auto-numbering system for your data, and Access is installed on your computer, you can import the Excel data to an Access database. In an Access database, you can create a field that automatically generates a unique number when you enter a new record in a table.

Automatically number rows - Microsoft Support (1)

What do you want to do?

  • Fill a column with a series of numbers

  • Use the ROW function to number rows

  • Display or hide the fill handle

Fill a column with a series of numbers

  1. Select the first cell in the range that you want to fill.

  2. Type the starting value for the series.

  3. Type a value in the next cell to establish a pattern.

    Tip:For example, if you want the series 1, 2, 3, 4, 5..., type 1 and 2 in the first two cells. If you want the series 2, 4, 6, 8..., type 2 and 4.

  4. Select the cells that contain the starting values.

  5. Drag the fill handle Automatically number rows - Microsoft Support (2) across the range that you want to fill.

    Note:As you drag the fill handle across each cell, Excel displays a preview of the value. If you want a different pattern, drag the fill handle by holding down the right-click button, and then choose a pattern.

    To fill in increasing order, drag down or to the right. To fill in decreasing order, drag up or to the left.

    Tip:If you don't see the fill handle, you might have to display it first. For more information, see Display or hide the fill handle.

    Note:These numbers aren't automatically updated when you add, move, or remove rows. You can manually update the sequential numbering by selecting two numbers that are in the right sequence, and then dragging the fill handle to the end of the numbered range.

Use the ROW function to number rows

  1. In the first cell of the range that you want to number, type =ROW(A1).

    The ROW function returns the number of the row that you reference. For example, =ROW(A1) returns the number 1.

  2. Drag the fill handle Automatically number rows - Microsoft Support (3) across the range that you want to fill.

    Tip:If you don't see the fill handle, you might have to display it first. For more information, see Display or hide the fill handle.

  • These numbers are updated when you sort them with your data. The sequence might be interrupted if you add, move, or delete rows. You can manually update the numbering by selecting two numbers that are in the right sequence, and then dragging the fill handle to the end of the numbered range.

  • If you are using the ROW function, and you want the numbers to be inserted automatically as you add new rows of data, turn that range of data into an Excel table. All rows that are added at the end of the table are numbered in sequence. For more information, see Create or delete an Excel table in a worksheet.

To enter specific sequential number codes, such as purchase order numbers, you can use the ROW function together with the TEXT function. For example, to start a numbered list by using 000-001, you enter the formula =TEXT(ROW(A1),"000-000") in the first cell of the range that you want to number, and then drag the fill handle to the end of the range.

Display or hide the fill handle

The fill handle Automatically number rows - Microsoft Support (4) displays by default, but you can turn it on or off.

  1. Select the File tab, and then selectOptions.

  2. In the Advanced category, under Editing options, select or clear the Enable fill handle and cell drag-and-drop check box to display or hide the fill handle.

Note:To help prevent replacing existing data when you drag the fill handle, make sure the Alert before overwriting cells check box is selected. If you don't want Excel to display a message about overwriting cells, you can clear this check box.

See Also

Overview of formulas in Excel

How to avoid broken formulas

Find and correct errors in formulas

Excel keyboard shortcuts and function keys

Lookup and reference functions (reference)

Excel functions (alphabetical)

Excel functions (by category)

Automatically number rows - Microsoft Support (2024)

FAQs

Automatically number rows - Microsoft Support? ›

Excel has a limit of 1,048,576 rows and 16,384 columns per sheet.

How do I auto populate answers in Excel? ›

Fill data automatically in worksheet cells
  1. Select one or more cells you want to use as a basis for filling additional cells. For a series like 1, 2, 3, 4, 5..., type 1 and 2 in the first two cells. ...
  2. Drag the fill handle .
  3. If needed, click Auto Fill Options. and choose the option you want.

What is the number of rows Excel supports? ›

Excel has a limit of 1,048,576 rows and 16,384 columns per sheet.

How do you autofill rows in numbers? ›

Note: To autofill from the Numbers menu bar, select the cells you want to autofill, choose Table > Autofill Cells, then choose an autofill option. Depending on the selected cells, some of the autofill options may not be available.

Can you auto generate numbers in Excel? ›

Unlike other Microsoft 365 programs, Excel does not provide a button to number data automatically. But, you can easily add sequential numbers to rows of data by dragging the fill handle to fill a column with a series of numbers or by using the ROW function.

How do I get Excel to automatically calculate numbers? ›

On the Formulas tab, in the Calculation group, click Calculation Options, and then click Automatic.

How do I get Excel to automatically count cells? ›

On the Formulas tab, click More Functions, point to Statistical, and then select one of the following functions:
  1. COUNTA: To count cells that are not empty.
  2. COUNT: To count cells that contain numbers.
  3. COUNTBLANK: To count cells that are blank.
  4. COUNTIF: To count cells that meets a specified criteria.

How do I get Excel to automatically calculate rows? ›

If you need to sum a column or row of numbers, let Excel do the math for you. Select a cell next to the numbers you want to sum, select AutoSum on the Home tab, press Enter, and you're done.

Top Articles
Latest Posts
Article information

Author: Jonah Leffler

Last Updated:

Views: 6275

Rating: 4.4 / 5 (45 voted)

Reviews: 92% of readers found this page helpful

Author information

Name: Jonah Leffler

Birthday: 1997-10-27

Address: 8987 Kieth Ports, Luettgenland, CT 54657-9808

Phone: +2611128251586

Job: Mining Supervisor

Hobby: Worldbuilding, Electronics, Amateur radio, Skiing, Cycling, Jogging, Taxidermy

Introduction: My name is Jonah Leffler, I am a determined, faithful, outstanding, inexpensive, cheerful, determined, smiling person who loves writing and wants to share my knowledge and understanding with you.