---
title: "timeZoneWithName:"
framework: foundation
role: symbol
role_heading: Type Method
path: "foundation/nstimezone/timezonewithname:"
---

# timeZoneWithName:

Returns the time zone object identified by a given identifier.

## Declaration

```occ
+ (instancetype) timeZoneWithName:(NSString *) tzName;
```

## Parameters

- `tzName`: The ID for the time zone.

## Return Value

Return Value The time zone in the information directory with a name matching tzName. Returns nil if there is no match for the name.

## See Also

### Creating Time Zones

- [timeZoneWithName:data:](foundation/nstimezone/timezonewithname:data:.md)
- [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)
