Mobatek Blog

Latest news, tips and tricks about MobaXterm
and other Mobatek applications

MobaXterm commandline parameters

MobaXterm commandline parameters

Posted on by MobaXterm dev team
Share:    Permalink




If you use MobaXterm extensively, you may need to know some advanced commandline settings in order to specify how MobaXterm should be started and to specify if it has to perform some automatic actions just after startup. This can be useful in order to automate some repetitive tasks or in order to include MobaXterm in a script.

Here is an exhaustive list of commandline parameters you can use:

  • You can run a shell script directly at MobaXterm startup. You just have to launch MobaXterm with the following command line:
    MobaXterm.exe <script_file>
    Be careful, the shell script has to be in Unix and not Dos format!

  • This command can be used to start a new instance of MobaXterm and immediately execute a given MobaXterm command
    MobaXterm.exe -exec "<Command>"


  • This command can be used to start a new tab inside a running instance of MobaXterm (or start a new instance of MobaXterm if no other instance is running) and immediately execute a given MobaXterm command
    MobaXterm.exe -newtab ["<Command>"]


  • This command can be used to start a bookmark by specifying its name.
    MobaXterm.exe -bookmark "<Bookmark_name>"
    Note: this only work for 1st level bookmarks: bookmarks from subfolders can not be invoked by this command


  • This command can be used to start a macro by specifying its name.
    MobaXterm.exe -runmacro "<Macro_name>"


  • This command can be used to start MobaXterm in the specified folder
    MobaXterm.exe -openfolder "<Folder_name>"


  • This command can be used to start MobaXterm that is immediately minimized into the system tray
    MobaXterm.exe -hideterm


  • This command can be used to exit MobaXterm when the given action is finished. This parameter should be combined with -bookmark or -exec
    MobaXterm.exe -exitwhendone


  • This command can be used to specify a path for MobaXterm configuration file MobaXterm.ini
    MobaXterm.exe -i "<Ini_file_path>"


  • This command can be used to write down some debug information in a log file MobaXterm.log
    MobaXterm.exe -log


  • This command can be used to install the right-click context menu in Windows explorer
    MobaXterm.exe -installshellext


  • This command can be used to install the URL protocol handler, in order for MobaXterm to be able to execute sessions from HTML pages
    MobaXterm.exe -installprotohandler


  • This command can be used to start MobaXterm configuration window
    MobaXterm.exe -config


  • This command can be used to start MobaXterm keyboard shortcuts configuration window
    MobaXterm.exe -shortcuts


  • This command can be used to start MobaXterm documentation
    MobaXterm.exe -doc


  • This command can be used to start MobaXterm embedded picture viewer program
    MobaXterm.exe -picview


  • This command can be used to start MobaXterm embedded text editor MobaTextEditor
    MobaXterm.exe -edit "<File1>"


  • This command can be used to start MobaXterm embedded diff tool
    MobaXterm.exe -compfiles "<File1>" "<File2>"


  • This command can be used to start MobaXterm embedded folders-diff tool
    MobaXterm.exe -compfolders


  • This command can be used to disable X server for the given MobaXterm instance
    MobaXterm.exe -noX


  • This command can be used to scale MobaXterm interface if the fonts are too small. You can try the following values: 120 (x1.25), 144 (x1.50) or 192 (x2.00)
    MobaXterm.exe -dpi 120