Written by Allen Wyatt (last updated February 4, 2023)
This tip applies to Excel 2007, 2010, 2013, 2016, 2019, 2021, and Excel in Microsoft 365
One of the handy features of Excel is that you can define names that refer to ranges of cells. (This is a big plus when you want to write formulas that make sense.) When you create a named range, Excel assumes that you want the name to be available from every worksheet within a workbook.
You can, however, specify that a name be valid only for the current worksheet. In this way you can define the same name on different worksheets in your workbook. Thus, you could have a range named MyRange on Sheet1, a range named MyRange on Sheet2, and also on Sheet3. To create names that are only applicable to a specific worksheet, follow these steps:
Figure 1. The New Name dialog box.
That's it. Now, if you go to a different worksheet, the name you defined will not be available from that worksheet—only from the worksheet in which it was defined.
There is a potential little quirk here that can lead to some interesting results. Note that in the "Refers To" box, the range shown is fully qualified—it shows the sheet on which you selected cells in step 1. If you select a different sheet in step 5, then your defined name is only available in whatever sheet you specified (in step 5), but it still refers to cells on a sheet other than that one. It will work just fine in your formulas, but it is just one potential "gotcha" you should watch for.
Finally, I should mention that there is a bit of shortcut you could use in the above-listed steps. You could also define the scope for your range name in this manner:
This approach—adding the sheet name to the beginning of the range name—results in the scope being set automatically to whatever sheet you specify.
ExcelTips is your source for cost-effective Microsoft Excel training. This tip (12237) applies to Microsoft Excel 2007, 2010, 2013, 2016, 2019, 2021, and Excel in Microsoft 365. You can find a version of this tip for the older menu interface of Excel here: Using the Same Range Name on Different Worksheets.
Program Successfully in Excel! This guide will provide you with all the information you need to automate any task in Excel and save time and effort. Learn how to extend Excel's functionality with VBA to create solutions not possible with the standard features. Includes latest information for Excel 2024 and Microsoft 365. Check out Mastering Excel VBA Programming today!
Each cell in a worksheet can hold quite a bit of information. If you want to see the information in the cell without the ...
Discover MoreGot some numbers and letters mixed up in the same cell? You may need to get rid of those letters so you are left with ...
Discover MoreWhen you add a new row of data to the bottom of the data of a worksheet, Excel may (or may not) copy formulas downward to ...
Discover MoreFREE SERVICE: Get tips like this every week in ExcelTips, a free productivity newsletter. Enter your address and click "Subscribe."
2023-02-06 14:03:06
Mechie
I mentioned the free Add-In from Jan Karel Pieterse called Name Manager in the Excel Tip that J. Woolley references below. (https://jkp-ads.com/excel-name-manager.asp) Another one of its features is the ability to "localize" or "globalize" a Range Name. Very handy. Just one of its many features.
2023-02-04 17:14:33
David Gray
Another useful property of worksheet-scoped names that are scoped to the worksheet in which the referenced cells exist is that when you copy the worksheet, the locally scoped name comes with the copy. In this way, formulas that reference the name refer to the same cells in the new worksheet, very handy for such things as monthly tabulation worksheets.
2023-02-04 16:27:07
Tomek
Further to my earlier comment:
This works well for names with workbook scope. For ranges with sheet scope you would need to precede the range name with <SheetName!>
eg., Range("Sheet1!MyData")
but it would still work.
2023-02-04 16:08:30
Tomek
Range names are a very useful tool, if used properly. I would like to comment on use of the defined names in macros.
If you refer to a named range in a macro, eg., Range("MyData"), and then insert or delete rows, columns etc., which results in the named range to move to different address, the macro will still run correctly.
If, on another hand you refer to a range like Range("B7:H14") and that range gets moved, the macro will still refer to the same address B7:H14. Addresses of ranges or even single cells are not updated when the cells are moved or ranges expanded.
2023-02-04 14:11:47
Philip
Note thaï name scopes are nog supporter in Excel for Mac … (like so Manu otter features of Excel)
2023-02-04 09:59:31
J. Woolley
For related discussion, see https://excelribbon.tips.net/T013007_Checking_the_Scope_of_a_Defined_Name.html
Got a version of Excel that uses the ribbon interface (Excel 2007 or later)? This site is for you! If you use an earlier version of Excel, visit our ExcelTips site focusing on the menu interface.
FREE SERVICE: Get tips like this every week in ExcelTips, a free productivity newsletter. Enter your address and click "Subscribe."
Copyright © 2025 Sharon Parq Associates, Inc.
Comments