Button Mapper makes it easy to map custom actions to your volume buttons or other buttons on your phone. Remap buttons to launch any app, shortcut or custom action

Assign custom actions to single presses, double taps and long presses of your phone's hardware buttons. Root is not required

Button Mapper can remap physical or capacitive keys and buttons, such as volume buttons, the home button on Samsung Galaxy devices, the camera button on Sony devices, and the capacitive home, back and recent apps keys found on many devices by ASUS, HTC, OnePlus, Xiaomi and other manufacturers

Button Mapper does not work when the screen is off, except for volume keys if your device is rooted

This app uses Accessibility services. Accessibility is used to detect when the physical or capacitive buttons are pressed on your device so they can be remapped to custom actions to accommodate your needs. It is not used to see what you type. Button Mapper does not collect or share any of your personal information

This app uses the Device Administrator permission. (BIND_DEVICE_ADMIN)
This permission is used to lock the screen if the "Turn screen off" action is chosen. If you want to remove this permission, open Button Mapper, click on the menu (three dots in the upper right corner) and select "Uninstall"

A few examples of keymapping you can do with Button Mapper:
-long press volume down to toggle your flashlight
-double tap your home button to launch your favorite app or shortcut
-long press your home button to turn off the screen
-double click the back button to open your notifications
-swap your back and recent apps keys
-use your volume buttons to adjust screen brightness
-long press home to toggle "do not disturb" mode
-press and hold the home button to quickly check your lockscreen messages, release to turn off the screen instantly
-and much more, the possibilities are endless

Additional features unlocked in the pro version:
-support for back button, recent apps button and camera button
-Swap volume keys on orientation change
-Default to media volume
-Homescreen lock
-Themes
-Customization of haptic feedback (vibration) on button press and long press

Actions that can be mapped to buttons or keys:
-Launch any app or shortcut
-Disable the button
-Home, back or recent apps
-Tasker intents (execute any task in Tasker)
-Turn screen off
-Toggle flashlight
-Quick settings
-Show notifications
-Power dialog
-Take screenshot
-Music: previous/next track and play/pause
-Adjust volume
-mute
-Toggle do not disturb
-Adjust brightness
-Now on tap (requires root)
-Menu button (requires root)
-Toggle WiFi
-Toggle orientation mode

Buttons supported:
-Home
-Back (PRO version only)
-Recent apps or Menu (PRO version only)
-Volume up
-Volume down
-Active edge on Pixel 2/Pixel 2 XL
-Bixby button on Samsung S8/S8+
-Camera button (PRO version only)
-Headsethook button
-Custom buttons: add other buttons (active, mute, etc) on your phone, headphones, even gamepads

Additional options:
-change the long press or double tap duration
-delay initial button press for better double tap operation
-disable Button Mapper while using specific apps

Troubleshooting:
-For Bixby on unrooted devices, make sure you don't disable Bixby Voice
-Make sure Button Mapper is exempt from any kind of battery optimization, task killers or other things that may interfere
-Button Mapper does not work with onscreen buttons (such as soft keys or the navigation bar) or the power button.
-Button Mapper does not work while the screen is off, except for the volume buttons if your device is rooted.
-The options shown in the app depend on the buttons available on your phone. Not all phones have home, back and recents buttons!

Support:
Please post on the Button Mapper Google+ community for questions and support:
plus.google.com/communities/103219324831995743794
From version Button Mapper: Remap your keys 0.58:
-add scroll up and scroll down actions (root only)
-add select/enter action (root only)
-improve long press for media volume
-fix Bixby remapping for root users
-improve stability
-bug fixes
All versions