8

How can I create keyboard shortcuts in Mail.app that do not require modifiers? For example, I'd like j/k to scroll the message pane. Maybe n/p to navigate between messages. Maybe N/P to navigate to unread messages. Maybe a to archve a message.

The key point here is that the shortcuts should not require modifiers: No Command, no Ctrl, no Option.

The gmail shortcuts are different, but similar in that they don't require modifiers.

3
  • I doubt this is possible.
    – user479
    Commented Jun 10, 2012 at 3:01
  • Man, I want this too...
    – Alex Wayne
    Commented Jul 25, 2012 at 23:10
  • I wonder if there is something like AutoHotKey for OSX. There is an AutoHotKey script that adds Gmail shortcuts to MS Outlook. Since all the actions are already available from the keyboard, just remapping the keys would do nicely. No, KeyRemap4MacBook doesn't do it (as far as I know), because it doesn't know which widget is in focus in Mail. (And I do want to be able to enter j and k into the Search field, say.)
    – hibbelig
    Commented Jan 10, 2013 at 0:53

5 Answers 5

8

Try GMailinator or the current fork. It's free and doesn't require configuration or start any extra process. GMailinator may not as flexible as keyboard macro software while if you're looking for exactly gmail shortcuts, it's a good fit.

BTW, if you don't have Xcode to build from source code, the compiled binary could be found at release tab.

1
  • I used Gmailinator for years, but unfortunately since Mail in macOS 14 (Sonoma) no longer supports plugins, solutions like Gmailinator will no longer work.
    – wunch
    Commented Dec 20, 2023 at 19:25
5

The link provided above has stopped updating. this guy has forked and updated for the newest Mail.app (comes with El Capitan) ankushg/GMailinator. You need to build from source code, unfortunately, but if you are geeky enough to use Gmail shortcuts, I believe this is easy.

1
  • Can confirm this works, but you do need to build from source (the included bundle does not work with Mail 9.2)
    – terrace
    Commented Feb 11, 2016 at 4:12
4

I've accomplished this with Keyboard Maestro. I've setup the navigation keys, then activate and deactivate them with Escape.

Setup a group scoped to Apple Mail that is activated via Escape:

Apple Mail group

Delete Gmail style:

Delete Gmail style

Move down:

Move down

Move up:

enter image description here

Create a shortcut for archiving. You could use e when Escape is activated to simulate Gmail's shortcut, but I prefer this as it doesn't matter what mode I am in:

Archive shortcut

You will need to bind a key to Archive in System Preferences:

Bind key to <code>Archive</code> in System Preferences

Confirm in Apple Mail:

Confirm keyboard shortcut

Use your imagination!

3
  • 1
    Could you maybe add a screenshot or a walkthrough on how to do this? This would greatly improve your answer. Commented Dec 8, 2013 at 13:15
  • @BartArondson, I have improved my answer. Thank you for the prompt. Commented May 29, 2014 at 17:50
  • 1
    @lipsum123483 Thanks just came across this as I'm experimenting returning to Mail.app from Mailmate. This still works great. One variant: you don't need to create a keyboard shortcut for Archive (actually there's now one out of the box), but KM can just execute the action "select a menu item". Commented Jun 30, 2017 at 17:52
2

I was revisiting this and found that there is a fork of Gmailinator that has been kept up to date - the current release supports Apple Silicon and Monterey.

1
  • This might be more useful as an edit to the Gmailinator answer than on its own.
    – nohillside
    Commented Aug 2, 2022 at 17:42
1

You can use a keyboard macro tool, but since Gmail shortcuts don't involve modifier keys, the challenge is making the shortcuts context-sensitive, i.e. you don't want them active in any place where you might be typing text (like the search bar or compose window).

I use Better Touch Tool and create a conditional activation group for this, with the following conditions:

  • App Name is "Mail"
  • Window Name begins with "Inbox —" (so the shortcuts don't trigger in the compose window; you can change this to suit your needs, but I personally only need them in the inbox)
  • Focused Element Role is not "AXTextField" (so the shortcuts don't trigger when typing in the search box)

Better Touch Tool activation group conditions

Then, you can add your Gmail keyboard shortcut triggers and actions to that group.

Side note: Launcher apps like Spotlight and Alfred are by default not considered separate windows. So, the keyboard shortcuts will still be active in them if Mail is the front-most window (i.e. the "App Name is Mail" condition is still true). For Alfred, there's a setting specifically to address this issue. Set Alfred Settings > Appearance > Options > Focusing: Compatibility Mode.

1
  • Really good solution now that Legacy Mail.app Plugins have been removed. I modified the second rule to "Window Name contains Inbox", so that shortcuts work in the "All Inboxes" view too. Also for the "E" (archive) shortcut in particular, I unchecked "Delete typed characters after recognition" in the key sequence editor
    – landen
    Commented Jan 27 at 6:19

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .