Running Angular 2 app in Android Emulator with NativeScript

This post is about running an Angular 2 app in Android emulator.

We have seen that the documentation provided on internet is not the way it should be. This is because it includes four entirely different setups (Node, Android SDK, NativeScript and GIT). Issues occurs and we end up in wasting much time in internet search to fix those issue. We know the issues well and hence have tried to document this process from scratch where you have just....
>>>> Windows 10 installed on your machine.  .... And Nothing Else

Please follow the mentioned steps in sequence (remember the only pre-requisite being Windows 10).

1) Install Node js version 6.7.0 or later. 

You can download the same from -

2) NodeJS version check.

Post node.js installation, open "Node.js command prompt" from Start menu. Check the node and npm versions. Make sure you have these or later versions.

For npm version : npm -v
For node version : node -v

3) Nativescript library for Nodejs installation.

Run the following command to install native script package from Node.js command prompt

npm install -g nativescript

4) Nativescript nodejs libriary installation verification.

To verify the telerik nativescript installation, type "tns" and hit enter in the command prompt.

5) Android SDK installation:

Go to the website -

Scroll to the bottom.

We don't need to install the entire Android Studio, just click on the highlighted link to download the Android Software Development Kit. Install the SDK after download.

Now, you should be seeing two applications installed in "All Programs" menu from Start button.

6) Android packages installation.

Right click SDK Manager and "Run as administrator".

Check three options under "Android 6.0 (API 23) and click "Install packages".

Also, Check four options under "Extras".

7) Android Virtual Device configuration.

Right click on AVD (Android Virtual Device) manager from "Start Menu" and click "run as administrator".

In AVD Manager home screen, click "Create" and enter the exact following information. Click OK.

After this, you should be seeing this screen.

8) Andriod HAXM installation.

Go to the folder - "C:\Program Files (x86)\Android\android-sdk\extras\intel\Hardware_Accelerated_Execution_Manager"

Double click - "intelhaxm-android.exe" to execute the wizard and finish the set up.

9) Andriod Emulator preview.

Now in AVD Manager, click on "Start" on the right side options. The following screen should appear.

10) Nativescript for Windows installation.

Open Command prompt from "Start" menu as an administrator and paste the following command and hit enter to execute.

@powershell -NoProfile -ExecutionPolicy Bypass -Command "iex ((new-object net.webclient).DownloadString(''))" 

Verify the set up by executing the below command.

tns doctor

If you see "No issues were detected" you are good to go!

11) GIT installation.

Go to the URL -

and click "Windows" under "Downloads" section. After download install the setup.

12) Nativescript's Angular 2 sample app setup.

Create a folder in any location in your drive. (say test)

Now, from start menu - Open "Git Bash" as an administrator.

In Git bash, go to the location where you have created the "test" folder. Paste the following to Git clone a sample nativescript app.

git clone
In Git bash, go to the repo folder

cd sample-Groceries

In Git bash, check out the version

git checkout angular-start

11) Sample app execution in Andriod simulator.

Open command prompt as an administrator and go to the "sample-Groceries" folder created in previous step. Paste the below command and hit enter to execute.

tns platform add android

now run the following command :

tns run android --emulator

You should be seeing the "Hello World" app hosted in the Android emulator.

12) Congratulation! 

You have successfully created and Angular 2 app in Android with NativeScript.

Note : Please post comments, in case you find any issues. Thanks!


  1. Make sure Virtualization is enabled in BIOS (advanced Firmware for windows 10)
    and install manually from

    after running installation batch file, silent_install.bat of downloaded zip file.

    tns run android -->Should open up the simulator!

  2. Play! is a small project, i really doubt it will became something really playable in future.

    Just get a portable Intel Atom device (z8750 or something like that), they are pretty cheap and somewhat powerful, although i dont think powerful enough for PCSX2.

  3. Hi, Great.. Tutorial is just awesome..It is really helpful for a newbie like me.. I am a regular follower of your blog. Really very informative post you shared here. Kindly keep blogging. If anyone wants to become a Front end developer learn from TypeScript Training in Chennai . or learn thru Javascript Training in Chennai.

  4. Google did take about two years to reach the 100,000 mark as selling mobile applications had not been as profitable for the Android developer as it is today. ShowBox APK

  5. The smart developers opt for responsive layout to keep the UI consistent across many devices. ShowBox APK Download

  6. Thus, the prospects for Android development are now potentially infinite as more and more unique Android apps are being created every day.ShowBox APK Download

  7. Based on the above comparison Samsung Galaxy S7 Edge, launched 6 months earlier than Apple iPhone 7 Plus is of better quality when it comes to hardware.
    Web Development Company


Comment Here