How to Display Current Date and Time in UTC/GMT in Mac Terminal


If you want to know that is the current time at UTC/GMT on your Mac, you can make use of the Terminal app and run the date command along with the Timezone (TZ) as GMT or with a -u flag.


Example 1: GMT Time using TZ

% TZ=GMT date

Fri Sep  8 11:54:18 GMT 2023
Mac Date and Time in GMT using Timezone TZ option

Example 2: UTC Time using -u flag

% date -u
Fri Sep  8 11:55:52 UTC 2023
Mac Date and Time using -u flag for UTC

This is not an AI-generated article but is demonstrated by a human on an M1 Mac running macOS Sonoma 14.0.

Please support independent contributors like Code2care by donating a coffee.

Buy me a coffee!

Buy Code2care a Coffee!

Facing issues? Have Questions? Post them here! I am happy to answer!

Author Info:

Rakesh (He/Him) has over 14+ years of experience in Web and Application development. He is the author of insightful How-To articles for Code2care.

Follow him on: X

You can also reach out to him via e-mail: rakesh@code2care.org

Copyright © Code2care 2024 | Privacy Policy | About Us | Contact Us | Sitemap