How to create duplicate pair of keyboard media keys for use with iTunes and streaming websites I've recently installed the Google Chrome extension Streamkeys which allows the user to use keyboard commands to perform common playback actions on popular streaming sites (Youtube, Soundcloud, and many major sites).

For macOS, Streamkeys default setting is to use the global Mac media keys (⏪ ▶/❚❚ ⏩).

Due to Chrome design, global keys cannot be rebound to use modifier keys like SHIFT + ▶/❚❚.

I like the idea of using the media keys for global Soundcloud/Youtube control, so what I'd like to do is to rebind the keyboard so that iTunes instead uses modifier keys like SHIFT + ▶/❚❚. That way, I can have the best of two worlds.

Question: How can I "duplicate" these three keys to a new location and use them to control iTunes, while still letting Chrome think that they are in their old location? In other words, I would effectively like two pairs of the same keys, only that one pair controls iTunes and one pair controls Chrome Streamkeys.

Is this even possible, and am I thinking about it the right way, when assuming that I would need "duplicates"? Just rebinding the keys would probably not work, since Chrome would still find the keys and "take them" for Streamkeys?

Note again: this is about global control. It is not the same as in-tab in Chrome or in-app in iTunes.
Install Karabiner

Which can be found there: Karabiner: a keyboard customizer for OS X

Analyse which keys are involved

Within Karabiner menu select Launch EventViewer... and type on
the music control key you would like to program.
Here is the output you should get:


Make a private.xml

Read the Karabiner documentation on the topic: private.xml Reference Manual

Create the ${HOME}/Library/Application Support/Karabiner/private.xml
with the following content:

&lt;?xml version="1.0"?&gt;
&lt;root&gt;
  &lt;item&gt;
    &lt;name&gt;Shift standard music control keys&lt;/name&gt;
    &lt;identifier&gt;Shift standard music control keys&lt;/identifier&gt;
    &lt;autogen&gt;__KeyToKey__ ConsumerKeyCode::MUSIC_PREV, ModifierFlag::SHIFT_L, ConsumerKeyCode::MUSIC_PREV&lt;/autogen&gt;
    &lt;autogen&gt;__KeyToKey__ ConsumerKeyCode::MUSIC_PLAY, ModifierFlag::SHIFT_L, ConsumerKeyCode::MUSIC_PLAY&lt;/autogen&gt;
    &lt;autogen&gt;__KeyToKey__ ConsumerKeyCode::MUSIC_NEXT, ModifierFlag::SHIFT_L, ConsumerKeyCode::MUSIC_NEXT&lt;/autogen&gt;
  &lt;/item&gt;
&lt;/root&gt;


Depending of your taste, use vi, emacs or TextEdit
(of course not Word).

If you want to be clean, I would suggest you to proceed as I did.

Create a source with the above content in:

${HOME}/Documents/src/Karabiner/music.xml


and then install it within the Karabiner directory:

cp ${HOME}/Documents/src/Karabiner/music.xml "${HOME}/Library/Application Support/Karabiner/private.xml"


( The "…" use is necessary because of the space within Application Support. ).

Load your private.xml

Tell Karabiner you will use a custom setting:


and load it:


Test it

Check that this let you achieve the mapping you want to get with Chrome.

I didn't check this part of your request, and I am not sure I understood
it fully.

Report success or failure, since this may help some other users .