Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I know there is a simple syntax for telling bash not to expand aliases. However, Google is not turning it up and I'm too lazy to read through man bash. Also, the answer should be on this website.

share|improve this question
up vote 9 down vote accepted

Put a backslash before the first character.

$ alias ls="echo foo"
$ ls
$ \ls
share|improve this answer
By the way, this is not a bash-specific feature. It's mandated by POSIX, and works in bash, ksh and zsh amongst others. – Gilles Oct 16 '10 at 11:40

You can use command shell builtin command. It will execute only commands found in the PATH or shell builtins. It won't execute aliases or shell functions.


alias ls='ls -l'
$ ls
drwxr-xr-x 3 user user 4096 2010-10-11 13:17 dir1
drwxr-xr-x 3 user user 4096 2010-10-15 15:37 dir2
$ function ls() {
> echo hello
> }
$ ls
$ command ls
dir1  dir2
share|improve this answer

Type shopt -u expand_aliases into the bash shell (the -u switch is for unset). I recommend reading the man page for shopt.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.