f you are trying to get it programmatically , you can use below line of code :
Objective-C:
NSString *bundleIdentifier = [[NSBundle mainBundle] bundleIdentifier];
Swift 3.0 :
let bundleIdentifier = Bundle.main.bundleIdentifier
Updated for latest swift It will work for both iOS and Mac apps.