Android Studio undo (Ctrl-Z) / redo (Ctrl-Y) not working

With the help of this answer, I have worked it out...

  1. Go into Settings (Ctrl+Alt + S)
  2. Type Redo in the search box.
  3. Double-click on the Redo result
  4. Select Add Keyboard Shortcut
  5. Press Ctrl+Y
  6. Click OK
  7. Click OK

To undo an action, do one of the following:

On the MainMenu, choose Edit | Undo. Press Ctrl+Z

To redo an action, do one of the following:

On the Main menu, choose Edit | Redo. Press Ctrl+Shift+Z


ctrl+Y deletes line by default in Android. If you want to change this behaviour, go to Keymap under Settings and set your desired shortcut for Redo action

By the way, the same question: how to configure intelliJ/Android Studio redo action for CTRL+Y instead of CTRL+Shift+Z