Wednesday, August 28, 2013

Setting up Apache Cordova iOS project on XCode

In the previous blogs we have seen how to set up a mgwt project on eclipse, Apache Cordova Android project on eclipse and Apache Cordova Android Project on Android Studio.

Now we will move to setting up an Apache Cordova iOS project on XCode. XCode is the default IDE Apple provides for developing iOS applications.

First we need to install XCode from Mac store. Just search for XCode and click on Install.

For creating a Cordova project we need to install nodejs and also cordova. So we need to repeat these installation steps on your mac also , if nodejs and cordova are not already installed on your mac.

Install NodeJS

Download the latest version of nodejs from the below link and install the nodejs library.

Then run the below command.

npm install -g cordova

Some times this command fails to run as it requires root or administrator privileges to install cordova for all the users using the mac. If you face any issues with root or administrator privilege, run the below command.

sudo npm install -g cordova

One the cordova installation is completed, we can create a cordova project.

Create iOS Project

Create an Apache Cordova iOS project running the below command.

cordova create IosCordovaTestApp

Now change to the project directory that was created in the previous step.

cd IosCordovaTestApp

Now add ios platform to the project created.

cordova platform add ios

Now we have created a cordova ios project, we will import it into XCode.

Configure in XCode

Launch XCode, and click on Open to import the project that is created.

Select the project, click on 'Open'.

Browse through the project you have created, IosCordovaTestApp --> platforms --> ios and select.

Once the project is imported, we can run it in an Simulators.

Simulators are available beside Stop button on the left corner of the XCode.

Click on Run button which will compile the application, launch the simulator, deploy the application in simulator and run the application in the simulator.

Once the simulator is launched and application is installed, we can see the Apache Cordova iOS project launched which will display a screen above.

We have just created a blank project and so this is fine for now.

Later we will modify the project with our changes and view them running the simulator.

We have completed setting up all the required tools and environment to build a cross platform mobile application. So in the next blogpost we can start building a demo app and run it on different mobile OS.


  1. Thanks for sharing such a great blog..Keep posting..

    JAVA Training

  2. This post covers how to get your app into xcode! Invaluable.

  3. Thanks for posting useful information.You have provided an nice article, Thank you very much for this one. And i hope this will be useful for many people.. and i am waiting for your next post keep on updating these kinds of knowledgeable things...Really it was an awesome article...very interesting to read..
    please sharing like this information......
    Android training in chennai
    Ios training in chennai

  4. Its an incredible joy perusing your post. It's brimming with data I am searching for and I want to post a remark that "The substance of your post is marvelous" Great work.
    android app development courses in chennai

  5. Hey Nice Blog!! Thanks For Sharing!!!Wonderful blog & good post.Its really helpful for me, waiting for a more new post. Keep Blogging!
    Web Design Training

  6. Nice and good article. It is very useful for me to learn and understand easily. Thanks for sharing your valuable information and time. Please keep updating.
    Top Web Design Training India

  7. One of the key features said to be coming to
    the HomePod is the ability to make or receive phone calls
    Read More At ios Online Training

  8. Thanks for sharing the steps to write an e-commerce blog. I think this is very useful especially for beginners.
    All those who are into e-commerce and wants to know more about it and re-commerce.
    mobile repairing training institute in hyderabad

  9. You have provided a nice article, Thank you very much for this one. And I hope this will be useful for many people. And I am waiting for your next post keep on updating these kinds of knowledgeable things.
    DOT NET Training in Chennai
    Hadoop Training in Chennai
    Android Training in Chennai
    Selenium Training in Chennai
    JAVA Training in Chennai
    German Classes in chennai
    PHP Training in Chennai
    PHP Training in Tambaram

  10. This comment has been removed by the author.

  11. appbiz360 is an iOS app development company with global presence and a portfolio most app developers dream of but can’t maintain.

  12. Good job! Fruitful article. I like this very much. It is very useful for my research. It shows your interest in this topic very well. I hope you will post some more information about the software. Please keep sharing!!
    SEO Training in Chennai
    SEO Training in Bangalore
    SEO Training in Coimbatore
    SEO Training in Madurai

  13. This is really helpful and informative, as this gave me more insight to create more

    ideas and solutions for my plan.keep update with your blog post.

    Website Design Company in Bangalore
    Website Development Company in Bangalore