Setting up the Kiosk mode

If you want a user to interact with your application and nothing else, you can configure the virtual device so that it turns into a kiosk mode, making it a single-purpose tool.

Locking an application

From Web browser

To kiosk an application, install & launch the application. Then go to the "Configuration" section of your device (https://X.X.X.X/configuration, where X.X.X.X is your instance IP address).

Configuration screenshot

Then using the form, you can kiosk the application by clicking on the toggle button:

Kiosk

From HTTP API

  1. From the instance web user interface, launch the application you want to kiosk
  2. To get the API reference, refer to DocumentationAPI ReferencePOST /configuration/kiosk
  3. Click on Try it outExecute

From Command Line

  1. Connect to your virtual device via SSH, as explained in section Accessing a Genymotion virtual device from SSH.
  2. Start the application you want to lock in kiosk mode.
  3. Once the application is started, run cmd activity kiosk start.

The status bar is hidden and cannot be scrolled down. The user cannot use the Back or Home buttons.

Unlocking an application

From Web browser

To unkiosk an application, go to the "Configuration" section of your device (https://X.X.X.X/configuration, where X.X.X.X is your instance IP address).

Configuration screenshot

Then using the form, you can unkiosk the application by clicking on the toggle button:

Kiosk

From HTTP API

  1. From the instance web user interface, go to DocumentationAPI ReferenceDELETE /configuration/kiosk
  2. Click on Try it outExecute

From Command Line

To unlock an application and disable the kiosk mode, run cmd activity kiosk stop. You can now exit the application. If you reboot your device, your application will still be locked.

TIP

If within your application you start another application, this might not work depending on how this application is started. For more information, please refer to the LockTask mode from Android DeviceOwner APIs.