How To Enable Camera in Android Emulator

By default when you create an Android Virtual Devices (AVD) in Android, the Camera is disabled. So if your application uses Camera API, it might not work properly in Android Emulator. Also SDCard must be defined in emulator in order to use Camera.

To enable Camera in your Android Emulator, just add following highlighted code in your AVD’s config.ini file. You can find the config.ini file under your user directory/.android folder.

File: ~/.android/config.ini


In case you don’t find the config.ini file or want to enable Camera support through Android SDK and AVD Manager, follow below simple steps.

Open Android SDK and AVD Manager:

Step 1: Add SD Card in AVD

In the SD Card setting, set the value for Size. To enable camera, the SD Card must be enabled in Emulator.

Step 2: Add Camera Support in Hardware under AVD

Now under Hardware section, click New button to add Camera hardware. It will open following Dialog box. Select Camera support from the Property dropdown and click Ok.

Step 3: Enable Camera Support in Hardware

The new hardware: Camera support is visible under Hardware section. Set its value to yes and save changes by pressing Edit AVD.

And that’s all. Just save the changes and launch the emulator. You’ll be able to start Camera application and take snaps (Default android pic) through it.


  • Bart 25 July, 2012, 17:30

    Thank you for this post :-) Regards, Bart

  • abcd 16 August, 2012, 2:26

    Is there any technique to close the android emulator properly. Every time it get hanged.

  • bob 16 August, 2012, 18:04

    there isn’t any camera support on my avd

  • vijay 18 August, 2012, 13:08

    camera support is not visible under hardware

    • Viral Patel 18 August, 2012, 13:54

      Hi, Which version of API you using for your AVD?

  • Jimmy 10 September, 2012, 14:48

    me too. i can’t see camera supprot.
    use the notebook(import camera) . I use eclipse version juno. And using AVD API7~API10.
    help me. T.T

  • Ian 24 October, 2012, 19:04

    Thanks for thise, quite useful!

  • Ashok Azad 6 November, 2012, 22:16

    Thanks for these, it is useful

  • Valluru Rajasekhar 7 January, 2013, 15:40

    Hi Viral Patel ,
    you post really helps me alot…… A special thanks to you

  • prayas mohanty 20 February, 2013, 17:53

    Hi Guys,
    Where is the code for the camera that AVD will be using ? Does it show live image or just a generated stuff ?


  • Madiraju Krishna Chaitanya 19 January, 2014, 11:49

    Hi Viral Patel,Thanks for the wonderful Post.Please posting these wonderful posts in the future.ALL THE BEST.MAY GOD BLESS YOU… :-)

  • Perihan 27 May, 2014, 3:04

    Thank you so much for this post. It is very helpful!

  • tia 23 June, 2014, 15:07

    hardware option is not showing under avd manager..i am using adt-bundle-windows-x86_64-20140321.reply asap

  • supervenus 3 January, 2015, 9:29

    usb camera is connected mypc. And camera example is running. But video disappear, and cross stripes appear!!! How to do ?!

  • Dinesh Madhup 11 April, 2015, 12:40

    Hi Viral,
    I am also facing problem of camera on android emulator. There is no such hardware option as you have described. Please reply me ASAP.

Leave a Reply

Your email address will not be published. Required fields are marked *


To post source code in comment, use [code language] [/code] tag, for example:

  • [code java] Java source code here [/code]
  • [code html] HTML here [/code]