macos external USB keyboard command key not working

I have a reliable external keyboard that worked normally with a macbook pro (2018). I've upgraded to a new macbook air and the command key isn't working with the external keyboard. For example I can't use any keyboard shortcuts such as -space for spotlight. It appears to be just the command key.

Other examples:

  • ⌘C, ⌘V not working
  • ⌘, for preferences not working
  • Menu bar items (such as Edit > Copy) have the ⌘C greyed out instead of black font.
  • Other keys work normally: tab, Enter, Ctrl-L (for clearing terminal screen for example).
  • Laptop keyboard working fine.

Attempted (failed) fixes:

  • Reboot
  • Reset SMC (also PRAM, NVRAM)
  • Check USB connections on different ports
  • Delete Libarary Prefs com.apple.HIToolbox.plist
  • Repeat the keyboard detection (Prefs > Keyboard > Change Keyboard Type...)

Keyboard type: Coolermaster Quicksight Rapid-i mechanical keyboard. I have used it successfully with work laptops (windows and macbook pro) as well as an iMac (2012).


Solution: Switch Modifier Key Assignment

For some reason the new macbook is detecting the Command key as Alt and vice-versa.

Preferences > Keyboard > Modifier Keys... and switch the and Alt keys.

Now it works. This was a painful experience so I'm sharing what I wish I had found online. I didn't discover that the command key was actually working until troubleshooting on https://keyboardchecker.com.

The Menu list shortcuts are still greyed out. I don't have a solution for this, but its cosmetic as the shortcuts still work, even ones I assign in keyboard prefs.