How to NSOject from NSDictionary into NSString?-Collection of common programming errors

Max has the correct casting syntax, but to be safe you’ll want to do some kind of instance check at runtime, since it’s not possible at compile-time in Objective-C to ensure that the type of an object in an array or dictionary is what you’re expecting:

NSObject *obj = [item objectForKey:@"link"];
if ([obj isKindOfClass:[NSString class]]) {
   NSString *stringValue = (NSString *)obj;
   // Do something with the NSString
} else {
   // You can alternatively raise an NSException here.
   NSLog(@"Serious error, we expected %@ to be an NSString!", obj);
}