How to Insert a Countdown Timer in an Excel Worksheet

Written by shawn mcclain
  • Share
  • Tweet
  • Share
  • Email

A countdown timer in an Excel spreadsheet could be helpful on a time-sensitive sheet, allowing the user to keep track of how much time they have left before a given event or deadline. While Excel doesn't have a countdown function or feature, you can use the built-in Visual Basic for Applications (VBA) programming language to create a countdown in a single Excel cell.

Skill level:
Moderately Challenging


  1. 1

    Open the Excel 2010 worksheet where you want to add a countdown timer. Right-click the cell where you want the timer to go and choose "Format Cells." Click "Custom" on the left side of the window that appears and then select "h:mm:ss" from the list on the right. Click "OK" to continue.

  2. 2

    Hold down "Alt" and press "F11" to open up the VBA console. Select your current worksheet from the list on the left side of the console. Click the small arrow next to the "Insert Userform" button at the top of the screen, which is the second button from the left side, and choose "Module" from the list of options that appear. Double-click "Module 1" when it appears in the list.

  3. 3

    Click the white space on the right side of the screen and enter the following code:

    Sub Countup()

    Dim Countdown As Date
    CountDown = Now + TimeValue("00:00:01")
    Application.OnTime Countdown, "Realcount"

    End Sub

    This code will allow the rest of the code to process once each second.

  4. 4

    Press enter to access a new line on the page. Enter to following code:

    Sub Realcount()

    Dim count As Range
    Set count = [E1]
    count.Value = count.Value - TimeSerial(0, 0, 1)
    If count <= 0 Then
    MsgBox "Countdown complete."
    Exit Sub
    End If
    Call Countup

    End Sub

    Change "E1" to whatever cell you want to use for the countdown. This code does the actual countdown and checks to see if the countdown is complete.

  5. 5

    Click the "X" in the upper right corner of the console to close it.

  6. 6

    Select the cell that you are using for your countdown and enter your desired countdown time. Be sure that you enter the hours, minutes and seconds, even if the hours and minutes are zero. "2:30" is two hours and thirty minutes; "0:2:30" is two minutes and thirty seconds.

  7. 7

    Click the "Developer" tab at the top of the screen, and then click the "Macros" button on the left side of the ribbon. Select "Countup" from the list and click "Run." Your countdown will start and it will continue until it gets to zero, when you will see a message box explaining that the countdown is complete.

Tips and warnings

  • If you want to make the numerical countdown bigger, you can select a number of cells, as long as your specified cell is in the upper left corner of the selection, and choose "Merge and Center" from the "Home" tab. Then change the font (from the home too), until the numbers are as large as you want them to be.

Don't Miss

  • All types
  • Articles
  • Slideshows
  • Videos
  • Most relevant
  • Most popular
  • Most recent

No articles available

No slideshows available

No videos available

By using the site, you consent to the use of cookies. For more information, please see our Cookie policy.