PIXEL
DOCK

I like the smell of Swift in the morning…

Code Sign Error: Provisioning Profile can’t be found.

Posted: | Author: | Filed under: iOS, Xcode | Tags: | 5 Comments »

Sometimes when you transfer your project to another computer and especially when you create a new developer certificate in the progress, you’ll run into difficulties. When you try to run your app on a device, Xcode will throw the following error:

Code Sign Error: Provisioning Profile '###ID###' can't be found.

The problem is that in your project’s project.pbxproj file the old provisioning profile identifiers are still lingering. You need to clean up that file so that Xcode can build your project without errors.

Here’s how you do that:

1. Close Xcode
2. Right click on your project’s .xcodeproj bundle to show it’s contents.
3. Open the .pbxproj file in a text editor of your choice (make a backup copy first if you feel paranoid)
4. Find all lines in that file that include the word PROVISIONING_PROFILE and delete them.
5. Open Xcode and clean your project
6. Build your project

80F04C2F14BDF2CD00851339 /* Ad Hoc */ = {
   isa = XCBuildConfiguration;
   buildSettings = {
      CODE_SIGN_IDENTITY = "iPhone Distribution: Caramelized GmbH";
      "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Distribution";
      GCC_PRECOMPILE_PREFIX_HEADER = YES;
      GCC_PREFIX_HEADER = "CaramelReader/Caramelized-Prefix.pch";
      INFOPLIST_FILE = "CaramelReader/Caramelized-Info.plist";
      IPHONEOS_DEPLOYMENT_TARGET = 5.1;
      PRODUCT_NAME = Caramelized;
      ↓ DELETE THIS LINE! ↓
      PROVISIONING_PROFILE = "8B3033A4-0E28-42F8-80FC-70B6C3C473C7"; 
      ↑ DELETE THIS LINE! ↑
      WRAPPER_EXTENSION = app;
   };
   name = "Ad Hoc";
};

5 Comments

  • 1

    S Ahnertsaid at

    Thanks! This helped me a lot.

  • 2

    Andreasaid at

    Thanks a lot! worked for me, I have also deleted the lines starting with “PROVISIONING_PROFILE[sdk=iphoneos*]”.
    But still can’t understand how Apple can leave bugs like this, very annoying..

  • 3

    mario gonzalezsaid at

    Thanks bro, you saved me a lot of time. god bless you

  • 4

    Kévin MACHADOsaid at

    Thanks !!!!!! 😉

  • 5

    Marc Watsonsaid at

    Thanks! Worked like a charm! Thanks for putting this out for others!


Leave a Reply