By default, your Mac adjusts its time zone based on your current location.
During testing, you might want to change the timezone of macOS to a different timezone. Maybe you want to test a website or app that is using the timezone and you want to make sure that another timezone is correctly used throughout the app.
When you change the timezone on your mac, it will automatically adjust its clock to the time in that time zone.
- Select "System Preferences" from the Apple menu (Apple icon).
- Under the "Date and Time" option, click on "Time Zone."
- Deselect the "Set Time Zone Automatically Using Current Location" and use the map to set the time zone manually.
- Or select your city from the "Closest City" menu. macOS will automatically display the correct date and time of the city you've selected.
Change timezone through command line
You can also use the command line to instantly change the time zone on your mac:
Where timezone is one of the valid timezones, which can be obtained from:
TestingBot offers an option to change the timezone during tests.