Please Note: This article is written for users of the following Microsoft Excel versions: 2007, 2010, 2013, 2016, 2019, Excel in Microsoft 365, and 2021. If you are using an earlier version (Excel 2003 or earlier), this tip may not work for you. For a version of this tip written specifically for earlier versions of Excel, click here: Specifying a Data Validation Error Message.

Specifying a Data Validation Error Message

Written by Allen Wyatt (last updated March 11, 2023)
This tip applies to Excel 2007, 2010, 2013, 2016, 2019, Excel in Microsoft 365, and 2021


If someone tries to enter a value into a cell that has a data validation rule defined, and that value is outside the bounds of the validation rule you have specified, they will see an error message. Excel allows you to modify the default error message to provide meaningful information to the user. When used in conjunction with the input message, data validation becomes a very powerful tool in developing worksheets to be used by others.

  1. Select the cell for which you want to define the messages.
  2. Display the Data tab of the ribbon.
  3. Click the Data Validation tool. Excel displays the Data Validation dialog box.
  4. Set any data validation rules desired.
  5. Click on the Error Alert tab. (See Figure 1.)
  6. Figure 1. The Error Alert tab of the Data Validation dialog box.

  7. Use the Style drop-down list to select different icons that should appear in the error message dialog box.
  8. Enter a message in both the Title and Error Message fields, as desired.
  9. Click on the OK button.

When the user enters an incorrect value and presses Enter or tries to move to another cell, a dialog box appears with your message.

You should realize that what the user can do once the error message dialog box is displayed is dependent on which error style you chose in step 6. For instance, if you choose the Stop style, the user can only retry their entry or cancel it. (In other words, you are forcing them to put in the right value.) If you choose the Warning style, then they are notified of their error, but they can still continue with the wrong value in the cell. Finally, the Information style is the gentlest reminder of all, and the user can still go on and accept the incorrect entry.

ExcelTips is your source for cost-effective Microsoft Excel training. This tip (12203) applies to Microsoft Excel 2007, 2010, 2013, 2016, 2019, Excel in Microsoft 365, and 2021. You can find a version of this tip for the older menu interface of Excel here: Specifying a Data Validation Error Message.

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

Deleting a User Account

Windows allows you to define individual user accounts for different people using a computer. If a person no longer needs ...

Discover More

Jumping to a Table Row

Need to jump to a particular row in a table? Word provides an easy way to jump to all sorts of things, but it doesn't ...

Discover More

Capitals After Colons

Do you want Word to always capitalize the first letter appearing after a colon? The program won't do it by default, but ...

Discover More

Solve Real Business Problems Master business modeling and analysis techniques with Excel and transform data into bottom-line results. This hands-on, scenario-focused guide shows you how to use the latest Excel tools to integrate data from multiple tables. Check out Microsoft Excel 2013 Data Analysis and Business Modeling today!

More ExcelTips (ribbon)

Limiting Entry of Names

When inputting information into a worksheet, you may need a way to limit what can be entered. This scenario is a prime ...

Discover More

Single-Use Drop-Down List

Want to create an easy drop-down list? You can do so by using the data validation features of Excel.

Discover More

Setting Data Validation Input Messages

When using data validation, you might want to have Excel display a message when someone starts to enter information into ...

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 5 - 3?

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.