Establishing a Naming Convention

Written by Allen Wyatt (last updated December 24, 2025)
This tip applies to Excel 2007, 2010, 2013, 2016, 2019, 2021, 2024, and Excel in Microsoft 365


Nate is designing a large workbook that has dozens of worksheets. He needs to create many names in the workbook for things like ranges, tables, formulas, and constants. Nate knows he won't be the only one to maintain this workbook down the road, so he's trying to develop an understandable naming convention for the names. This makes him wonder what the best practice is in this area.

The problem with a phrase such as "best practice" is that it makes people think there is a single, best approach when that may not be the case. It certainly is not the case when it comes to determining a naming convention like Nate desires. In fact, there are several different approaches you can take to naming, as will become apparent.

Every naming convention involves the use of a prefix of some sort that indicates the type of element to which the name applies. For instance, you might prefix formulas with the letter "f" or the letters "fo" and tables with "t" or "tbl." It doesn't matter if you use one, two, or three characters; there are pros and cons to each approach. The idea is that your prefix should be understandable and unambiguous.

Your prefix is typically followed by a word or two that details the purpose of the item. This is where some folks have formalized notation. Since Excel names cannot contain spaces, notation typically differs in how capital letters and underscores are used. Here is an example of what is often referred to as Hungarian Notation in names:

rngStartDates

Note that the prefix is all lowercase and the purpose words each start with a capital letter. The purpose words should be clear, meaningful, and concise. Sometimes you may find it more understandable to separate the prefix from the purpose words with an underscore:

rng_StartDates

The use of underscores in this manner is sometimes referred to as Snake Case, though technically Snake Case doesn't do prefixes or any capitalization:

start_dates

You can discover more about the formal names, such as Hungarian Notation and Snake Case, at this site:

https://www.encyclopedia-excel.com/vba-naming-conventions-how-to-write-good-variable-names-vba-tutorial

Note that this site is about naming variables in VBA, but the concepts are just as applicable to naming objects and elements in an Excel workbook. Personally, I find that underscores between the prefix and the purpose words are advantageous if your prefix is only a single character or two. For instance, if you are using a single letter for tables, such as "t" or "T," then I find the second and third names here clearer than the first:

tSeasonAdjustments
t_SeasonAdjustments
T_SeasonAdjustments

The underscore may be overkill, however, if you use three lowercase characters for the prefix:

tblSeasonAdjustments

This boils down to personal preference and what you find easiest to implement and understand. With or without an underscore, you could use the following as prefixes:

  • rng (range)
  • tbl (table)
  • col (column)
  • row (row)
  • fn (function)
  • frm (formula)
  • cnst (constant)
  • lst (list)
  • cht (chart)

Besides a prefix and purpose words, you may also want to include an indication of where the object or item is located. For instance, if a constant that defines the target margin is located on a worksheet named Details, then you might name the constant in this manner:

cnst_TargetMargin_Details

The structure and purpose of each name is, again, entirely up to you and what makes sense. It can be especially important to include a worksheet name in a name if the worksheet is normally hidden.

When you define names, there are several places that this can be done, depending on what is being named. The Name Manager is the key place if you are naming ranges, constants, and formulas. However, tables are named using the Table Name box on the Table Design tab of the ribbon, charts are named using the Name Box, and

I should also mention that if there really is a "best practice" in naming conventions, that practice would be consistency. Once you settle on an approach to naming things, you need to consistently apply that approach. If you fail to do so, then you really don't have a convention, and your names will be a mess.

Finally, once you decide on a naming convention, you'll want to document it somewhere. If you are developing a naming convention that will be used in a single workbook, then you should consider documenting it in a worksheet within that workbook. (You can even hide the worksheet if you think it might otherwise detract from the use of the workbook.) If you are developing a convention that you will use in multiple workbooks, then create a separate document that shows your convention and explains why you made the decisions that you did. Any documentation you put together will be invaluable for people who may need to maintain your workbooks in the future.

ExcelTips is your source for cost-effective Microsoft Excel training. This tip (10055) applies to Microsoft Excel 2007, 2010, 2013, 2016, 2019, 2021, 2024, and Excel in Microsoft 365.

Author Bio

Allen Wyatt

With more than 50 non-fiction books and numerous magazine articles to his credit, Allen Wyatt is an internationally recognized author. He is president of Sharon Parq Associates, a computer and publishing services company. ...

MORE FROM ALLEN

Displaying an Input Format in a Cell

Want to show a user, in a cell, what you expect their input to look like? Unfortunately, it cannot be done natively in ...

Discover More

Hiding Outline Symbols

Outline symbols are automatically displayed by Excel when you add subtotals or organize your data using an outline. If ...

Discover More

Deleting All Graphics

Graphics can really add pizzazz to a worksheet, but they can also present some drawbacks. If you want to get rid of all ...

Discover More

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!

More ExcelTips (ribbon)

Changing Your Name

One of the many pieces of information that Excel keeps track of is your name. If you want to change your name for Excel's ...

Discover More

Help for Older Excel Versions

If you are using an older version of Excel, you may discover one day that the online help system no longer works. This ...

Discover More

Starting in Safe Mode

By using a command-line switch, Excel can be started in safe mode. This means that the program is loaded with bare-bones ...

Discover More
Subscribe

FREE SERVICE: Get tips like this every week in ExcelTips, a free productivity newsletter. Enter your address and click "Subscribe."

View most recent newsletter.

Comments

If you would like to add an image to your comment (not an avatar, but an image to help in making the point of your comment), include the characters [{fig}] (all 7 characters, in the sequence shown) in your comment text. You’ll be prompted to upload your image when you submit the comment. Maximum image size is 6Mpixels. Images larger than 600px wide or 1000px tall will be reduced. Up to three images may be included in a comment. All images are subject to review. Commenting privileges may be curtailed if inappropriate images are posted.

What is 2 + 7?

There are currently no comments for this tip. (Be the first to leave your comment—just use the simple form above!)


This Site

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.

Newest Tips
Subscribe

FREE SERVICE: Get tips like this every week in ExcelTips, a free productivity newsletter. Enter your address and click "Subscribe."

(Your e-mail address is not shared with anyone, ever.)

View the most recent newsletter.