Whatbox Logo

Wiki > Midnight Commander


GNU Midnight Commander (also known as mc, the command used to start it) is a free cross-platform orthodox file manager and a clone of Norton Commander. It was started by Miguel de Icaza in 1994.

It's a feature rich full-screen text mode application that allows you to copy, move and delete files and whole directory trees, search for files and run commands in the subshell. Internal viewer and editor are included.

Midnight Commander is based on versatile text interfaces, such as Ncurses or S-Lang, which allows it to work on a regular console, inside an X Window terminal, over SSH connections and all kinds of remote shells.


  1. Connect to your slot through SSH

  2. Download the latest source tarball

     wget http://ftp.midnight-commander.org/mc-4.8.27.tar.xz
  3. Extract the source tarball

     tar xvJf mc-4.8.27.tar.xz
  4. Enter the source directory

     cd mc-4.8.27
  5. Configure the installation

     ./configure --prefix=$HOME --with-screen=ncurses
  6. Begin compiling the application. This process may take some time to complete.

  7. Install the application

     make install
  8. (Optional) Remove the source code:

     cd ..
     rm -r mc-4.8.27


  1. Add the bin directory to your PATH (if you've done this previously, you do not need to do it again)

     echo "PATH=\$HOME/bin:\$PATH" >> ~/.bashrc && source ~/.bashrc
  2. Start Midnight Commander


For more usage examples and documentation use mc's documentation


Follow these steps to allow Midnight Commander to work better with PuTTY:

  1. Add the following line to your .bashrc file by running this command

     echo "export NCURSES_NO_UTF8_ACS=1" >> ~/.bashrc
  2. Reload your .bashrc file

     source ~/.bashrc

Mouse Support

Follow these steps if Midnight Commander does not work with your mouse:

  1. Add the following line to your .bashrc file by running this command

     echo "alias mc='TERM=linux mc -x'" >> ~/.bashrc
  2. Reload your .bashrc file

     source ~/.bashrc


To update Midnight Commander, follow the installation steps again using the latest version.