How to Fix Excel #NAME? Error with Sheet-Specific Named Ranges
Question details
The user is encountering a #NAME? error when a formula references a named range on a specific worksheet.

- Product
- Excel
- Device & OS
- not provided
- Scenario
- Using a cross-sheet formula (e.g., =IF(D66>0,'41'!Rate+$G$18,0)) where the named range might be missing or assigned the wrong scope.
- Observed behavior
- The formula returns a #NAME? error because Excel cannot recognize the referenced named range on that specific worksheet.
Before modifying your named ranges, verify that the target worksheet exists and is spelled exactly as it appears in your formula, including spaces and special characters.
Verify and Correct Scope in the Name Manager
Use the Name Manager tool to check if the named range exists for the specific worksheet and recreate it if the scope is incorrect.
In Excel, named ranges can be scoped to either the entire workbook or a specific worksheet. If a formula looks for a worksheet-specific name (like '41'!Rate) but the name is scoped to the workbook or a different sheet, Excel will return a #NAME? error.
Navigate to the 'Formulas' tab on the Excel ribbon and click on 'Name Manager'.
Look through the list for the name in question (e.g., 'Rate'). Check the 'Scope' column to see if it is scoped specifically to the worksheet causing the error (e.g., '41').
If the name is assigned to the wrong scope, select it and click 'Delete'. (Note: Excel does not allow you to change the scope of an existing named range directly).
Click 'New' in the Name Manager. Enter the name, select the specific worksheet from the 'Scope' dropdown menu, select the correct cell references in 'Refers to', and click 'OK'.

Use Direct Cell References Instead of Named Ranges
Bypass named range scope issues entirely by using absolute cell references in your formulas.
Delete and Recopy the Affected Worksheet
If you recently duplicated a worksheet but the sheet-specific names didn't carry over properly, recopying the sheet might fix the problem.
Easily Manage Sheet-Specific Named Ranges with WPS Spreadsheet
WPS Spreadsheet offers an intuitive Name Manager that allows you to quickly view, edit, and define named ranges for both workbook and worksheet scopes, making formula troubleshooting a breeze.
- 1. Open Your File: Launch WPS Spreadsheet and open the workbook containing the #NAME? errors.
- 2. Access the Name Manager: Navigate to the 'Formulas' tab on the ribbon and click on 'Name Manager'.
- 3. Review Scopes: Check the list of named ranges to verify if they are scoped to the correct worksheet or the entire workbook.
- 4. Add or Edit Names: Click 'New' to easily recreate missing sheet-specific named ranges to fix your formulas.

Frequently Asked Questions
What is the difference between workbook and worksheet scope in named ranges?
A workbook-scoped named range can be referenced normally across any worksheet in the file. A worksheet-scoped named range is local to a specific sheet; to reference it from another sheet, you must include the sheet name in the formula (e.g., 'Sheet1'!MyRange).
Why does my formula work on one sheet but show a #NAME? error on another?
This happens when the named range used in the formula is scoped only to the original sheet. When you duplicate the formula on a new sheet, Excel looks for a local named range that hasn't been created yet.
Can I change the scope of an existing named range in Excel?
No, Excel does not allow you to directly edit the scope of a named range after it has been created. You must delete the incorrect named range and create a new one with the appropriate scope.
How do I reference a worksheet-scoped named range in a formula?
You must prefix the named range with the specific worksheet name followed by an exclamation mark. For example, if the named range is 'Total' on a sheet named 'Q1', you would write 'Q1'!Total.




