Skip to content

Most visited

Recently visited


Supporting Game Controllers

Dependencies and prerequisites

  • Android 2.3 (API level 9) or higher.

You should also read

Try it out

Download the sample

You can greatly enhance the user experience in your game by letting players use their favorite game controllers. The Android framework provides APIs for detecting and processing user input from game controllers.

This class shows how to make your game work consistently with game controllers across different Android API levels (API level 9 and up), and how to enhance the gaming experience for players by supporting multiple controllers simultaneously in your app.


Handling Controller Actions
Learn how to handle user input from common input elements on game controllers, including directional pad (D-pad) buttons, gamepad buttons, and joysticks.
Supporting Controllers Across Android Versions
Learn how to make game controllers behave the same across devices running different versions of Android.
Supporting Multiple Game Controllers
Learn how to detect and use multiple game controllers that are simultaneously connected.
This site uses cookies to store your preferences for site-specific language and display options.

Get the latest Android developer news and tips that will help you find success on Google Play.

* Required Fields


Follow Google Developers on WeChat

Browse this site in ?

You requested a page in , but your language preference for this site is .

Would you like to change your language preference and browse this site in ? If you want to change your language preference later, use the language menu at the bottom of each page.

This class requires API level or higher

This doc is hidden because your selected API level for the documentation is . You can change the documentation API level with the selector above the left navigation.

For more information about specifying the API level your app requires, read Supporting Different Platform Versions.

Take a short survey?
Help us improve the Android developer experience. (April 2018 — Developer Survey)