---
title: NSTimeZone
framework: foundation
role: symbol
role_heading: Class
path: foundation/nstimezone
---

# NSTimeZone

Information about standard time conventions associated with a specific geopolitical region.

## Declaration

```swift
class NSTimeZone
```

## Overview

Overview In Swift, this type bridges to TimeZone; use NSTimeZone when you need reference semantics or other Foundation-specific behavior. Time zones represent the standard time policies for a geopolitical region. Time zones have identifiers like “America/Los_Angeles” and can also be identified by abbreviations, such as PST for Pacific Standard Time. You can create time zone objects by ID with init(name:) and by abbreviation with init(abbreviation:). note: Time zone database entries such as “America/Los_Angeles” are IDs, not names. An example of a time zone name is “Pacific Daylight Time”. Although many NSTimeZone symbols include the word “name”, they actually refer to IDs. Time zones can also represent a temporal offset—either plus or minus—from Greenwich Mean Time (GMT). For example, the temporal offset of Pacific Standard Time is 8 hours behind Greenwich Mean Time (GMT-8). You can create time zone objects with a temporal offset by using init(forSecondsFromGMT:). You typically work with system time zones rather than creating time zones by identifier or by offset. The system class property returns the time zone currently used by the system, if known. This value is cached once the property is accessed and doesn’t reflect any system time zone changes until you call the resetSystemTimeZone() method. The local class property returns an autoupdating proxy object that always returns the current time zone used by the system. You can also set the default class property to make your app run as if it were in a different time zone than the system. tip: You can’t use NSTimeZone APIs to change the time zone of the device or of other apps. NSTimeZone is toll-free bridged with its Core Foundation counterpart, CFTimeZone. See Toll-Free Bridging for more information on toll-free bridging. important: The Swift overlay to the Foundation framework provides the TimeZone structure, which bridges to the NSTimeZone class. For more information about value types, see Working with Foundation Types.

## Topics

### Working with System Time Zones

- [local](foundation/nstimezone/local.md)
- [system](foundation/nstimezone/system.md)
- [resetSystemTimeZone()](foundation/nstimezone/resetsystemtimezone().md)
- [default](foundation/nstimezone/default.md)

### Creating Time Zones

- [init(name:)](foundation/nstimezone/init(name:).md)
- [init(name:data:)](foundation/nstimezone/init(name:data:).md)
- [init(abbreviation:)](foundation/nstimezone/init(abbreviation:).md)
- [init(forSecondsFromGMT:)](foundation/nstimezone/init(forsecondsfromgmt:).md)
- [knownTimeZoneNames](foundation/nstimezone/knowntimezonenames.md)
- [abbreviationDictionary](foundation/nstimezone/abbreviationdictionary.md)

### Getting Time Zone Information

- [name](foundation/nstimezone/name.md)
- [abbreviation](foundation/nstimezone/abbreviation.md)
- [abbreviation(for:)](foundation/nstimezone/abbreviation(for:).md)
- [secondsFromGMT](foundation/nstimezone/secondsfromgmt.md)
- [secondsFromGMT(for:)](foundation/nstimezone/secondsfromgmt(for:).md)
- [data](foundation/nstimezone/data.md)
- [timeZoneDataVersion](foundation/nstimezone/timezonedataversion.md)
- [NSTimeZone.NameStyle](foundation/nstimezone/namestyle.md)

### Working with Daylight Savings

- [isDaylightSavingTime](foundation/nstimezone/isdaylightsavingtime.md)
- [isDaylightSavingTime(for:)](foundation/nstimezone/isdaylightsavingtime(for:).md)
- [daylightSavingTimeOffset](foundation/nstimezone/daylightsavingtimeoffset.md)
- [daylightSavingTimeOffset(for:)](foundation/nstimezone/daylightsavingtimeoffset(for:).md)
- [nextDaylightSavingTimeTransition](foundation/nstimezone/nextdaylightsavingtimetransition.md)
- [nextDaylightSavingTimeTransition(after:)](foundation/nstimezone/nextdaylightsavingtimetransition(after:).md)

### Comparing Time Zones

- [isEqual(to:)](foundation/nstimezone/isequal(to:).md)

### Describing Time Zones

- [localizedName(_:locale:)](foundation/nstimezone/localizedname(_:locale:).md)
- [description](foundation/nstimezone/description.md)

### Recognizing Notifications

- [NSSystemTimeZoneDidChange](foundation/nsnotification/name-swift.struct/nssystemtimezonedidchange.md)

### Initializers

- [init(coder:)](foundation/nstimezone/init(coder:).md)

## Relationships

### Inherits From

- [NSObject](objectivec/nsobject-swift.class.md)

### Conforms To

- [CVarArg](swift/cvararg.md)
- [Copyable](swift/copyable.md)
- [CustomDebugStringConvertible](swift/customdebugstringconvertible.md)
- [CustomStringConvertible](swift/customstringconvertible.md)
- [Equatable](swift/equatable.md)
- [Escapable](swift/escapable.md)
- [Hashable](swift/hashable.md)
- [NSCoding](foundation/nscoding.md)
- [NSCopying](foundation/nscopying.md)
- [NSObjectProtocol](objectivec/nsobjectprotocol.md)
- [NSSecureCoding](foundation/nssecurecoding.md)
- [Sendable](swift/sendable.md)
- [SendableMetatype](swift/sendablemetatype.md)
