It is difficult work with the Terminal if you can't type the tilde. Does anybody know how to do this using a Spanish keyboard?

  • I remember keeping a text file around so I could copy paste the tilde on old unix workstations. Was a real hassle and luckily OS X has better support.
    – bmike
    Commented Dec 14, 2015 at 20:18

2 Answers 2


Using a Spanish keyboard and Spanish keybindings the tilde is altñ. Using English keybindings (System Preferences -> Keyboard -> Input Sources) and a Spanish keyboard it's still altn. If you immediately enter a / afterwards, you don't need an extra space.

Note: On some keyboards the two alt keys are different. To get the tilde, you may have to use the alt gr key located to the right of the spacebar.


On my Windows 10 and Ubuntu Linux with Spanish keyboard layout it is Alt Gr 4.

On Windows you will have to press space to only get the ~. Or something else that cannot be combined with the ~ like for example ã.

On my Linux I directly get the ~ character, but that behaviour is configurable.

I know it's the apple section. But I found this answer with Google searching for Windows and Linux. So I think my answer might be helpful.

  • No macos does it differently
    – mmmmmm
    Commented Oct 14, 2020 at 21:52

You must log in to answer this question.

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