SECOND Function – Examples in Excel, VBA, Google Sheets

Written by

Editorial Team

Reviewed by

Steve Rynearson

Last updated on November 6, 2023
Download Example Workbook

Download the example workbook

This tutorial demonstrates how to use the SECOND Function in Excel to get the seconds from a time.

Second Main function

SECOND Function Examples

The SECOND Function returns the second number of a time:



SECOND and TIME Functions

Using the TIME and SECOND Functions you can create a new time with the second number from the original time:



SECOND in Google Sheets

The SECOND Function works exactly the same in Google Sheets as in Excel:

Second Google sheet

SECOND Examples in VBA

You can also use the SECOND function in VBA. Type:


For the function arguments (serial_number, etc.), you can either enter them directly into the function, or define variables to use instead.

AI Formula Generator

Try for Free

Excel Practice Worksheet

practice excel worksheet

Practice Excel functions and formulas with our 100% free practice worksheets!

  • Automatically Graded Exercises
  • Learn Excel, Inside Excel!

Free Download

Return to List of Excel Functions