How to get local time on iOS [duplicate]
问题 This question already has answers here : Retrieving current local time on iPhone? (7 answers) Closed 6 years ago . I just noticed that NSDate *nowDate = [NSDate date]; gives me GMT+0 Time and not the local time. So basically on my iPad it's 13:00 and the output of this code is 12:00. How do I get local time properly? 回答1: Give it a Shot ! NSDate* sourceDate = [NSDate date]; NSTimeZone* sourceTimeZone = [NSTimeZone timeZoneWithAbbreviation:@"GMT"]; NSTimeZone* destinationTimeZone = [NSTimeZone