In Linux terminal if I run a command like:

$ node httserver.js

The command runs and by doing ctrl + c the program is terminated and new line comes in terminal for us to enter a command.

I felt ctrl + c as the macOS terminal keyboard combo to do that but it doesn’t work.


7 Answers 7


The accurate answer for MAC Keyboard on terminal is:

Command + . (dot/period)

This is equivalent to Ctrl + C or break.

Refer to the:

Terminal Help > Keyboard Shortcuts > Other Shortcuts > Break

The Control or Ctrl key is not a regular modifier in macOS.

However, if you are using a regular Windows keyboard with macOS then Ctrl + C works since there is no Command key in this case.

  • confirmed, other answers seem to be confused. Command+. works in OS X (Mac) Terminal application for sending an interrupt with a Mac keyboard. Control+C, Control+Z, Shift+Command+C, kill commands do not work in this setting. you cannot send a kill command while another command is actively running.
    – Brian D
    Commented Oct 15, 2020 at 22:25


Ctrl + C

It should be the same as Linux.

Duplicate of: this question

  • Ctrl + c is actually intercepted by macOs to open settings
    – lazizanie
    Commented Jun 8, 2023 at 6:44

Try Ctrl + Z

Or you can use kill Command. For further information see man kill command for manual of kill command and you can get some guidance from this link about how to use kill command.

  • ctrl-z does NOT do this. And "Or you can use the kill command" does not make any sense. Ctrl-Z and kill are completely and utterly different. I dont think you know what Ctrl-z does Commented Jun 15, 2022 at 18:19
  • I found this worked in visual studio for mac terminal session
    – Rob Bowman
    Commented Feb 8, 2023 at 7:51

Try Shift + Command + C worked for a friend.

  • This opens the color picker on my system. Commented Jan 8 at 9:14

If you are using iterm2, you might need to look into Preferences -> Keys -> Remap Modifiers. In my case, control (^) was mapped to something else by default. After mapping it to control (^), the shortcut worked.


Typing Ctrl + h took me to a help thing where it showed me the letter to type to exit. In my case, it indicated I had to use Ctrl + q.


If you are using VSCode: Ctrl+Z works just fine.

You must log in to answer this question.

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