Please Note: This article is written for users of the following Microsoft Excel versions: 2007, 2010, 2013, 2016, 2019, and Excel in Microsoft 365. 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: Plotting Times of Day.

Plotting Times of Day

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


Richard has some source data that shows the date and time displayed in the format dd/mm/yy hh:mm, but when he creates a chart from that data, the only thing that is plotted is the date. He is wondering if there is a way of plotting the times on the chart, as well as the date.

There are several ways you can approach this issue, depending on the type of chart you want to create. If you create an X-Y scatter chart, the date and time should plot automatically. This is not the case if you choose to create a bar, column line, or any other type of chart. In those cases, the X axis is created from equally spaced values, so you won't get exactly what you want.

If you don't want to use a scatter chart, then you could simply modify the data in your source. Add a column that represents the hour of the day, derived through the HOUR function. For instance, if you have your date and time in column B, add a column C and fill it with formulas such as =HOUR(B3). The result is a bunch of numbers representing the hour of the day, 0 through 23. This can chart very easily in any manner desired.

If that doesn't fit your needs, then go ahead and create the chart as you normally would. Then, if you are using Excel 2007 or Excel 2010 right-click the X axis and choose Format Axis from the Context menu. You should see the Format Axis dialog box and choose Number at the left of the dialog box. (See Figure 1.)

Figure 1. The number options of the Format Axis dialog box.

You can display the equivalent controls in Excel 2013 or a later version by right-clicking the axis and choosing Format Axis from the Context menu. Excel displays the Format Axis pane at the right side of the screen. The pane should already be set to Axis Options | Axis Options (sounds redundant; I know). All you need to do is expand the Number group at the bottom of the pane. (See Figure 2.)

Figure 2. The Format Axis pane.

Choose one of the formats for the axis under either the Date or Time categories. You may have to play a bit with your selection, experimenting to find out what works best. Quite honestly, what works best in one situation won't necessarily work best in another because of the nature of the data being charted.

ExcelTips is your source for cost-effective Microsoft Excel training. This tip (9547) applies to Microsoft Excel 2007, 2010, 2013, 2016, 2019, and Excel in Microsoft 365. You can find a version of this tip for the older menu interface of Excel here: Plotting Times of Day.

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

Saving Documents as Read-Only by Default

When you save your documents, you can specify that they be saved in a "read-only" format so that they cannot be changed ...

Discover More

Choosing a Character Size in the Equation Editor

The Equation Editor is a handy tool, particularly for those who must include mathematical equations in their documents. ...

Discover More

Finding Related Words

One part of the grammar tools provided with Word is a thesaurus that helps you find all sorts of word variations. One ...

Discover More

Excel Smarts for Beginners! Featuring the friendly and trusted For Dummies style, this popular guide shows beginners how to get up and running with Excel while also helping more experienced users get comfortable with the newest features. Check out Excel 2013 For Dummies today!

More ExcelTips (ribbon)

Changing Axis Tick Marks

Create a chart in Excel, and you may find that the tick marks shown on the axes in the chart aren't to your liking. It is ...

Discover More

Using Go To to Jump to a Chart Sheet

Create a chart on its own worksheet, and you can display it by simply clicking the tab at the bottom of the Excel work ...

Discover More

Labeling X-Y Scatter Plots

Figuring out how to get the data points in an X-Y scatter plot labeled can be confusing; Excel certainly doesn't make it ...

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 two more than 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.