B.2. Initial Options

The initial options specify parameters for the Emacs session. This section describes the more general initial options; some other options specifically related to the X Window System appear in the following sections.

Some initial options affect the loading of init files. The normal actions of Emacs are to first load site-start.el if it exists, then your own init file ~/.emacs if it exists, and finally default.el if it exists; certain options prevent loading of some of these files or substitute other files for them.

-t device, -terminal=device

Use device as the device for terminal input and output.

-d display, -display=display

Use the X Window System and use the display named display to open the initial Emacs frame.

-nw, -no-windows

Don't communicate directly with the window system, disregarding the DISPLAY environment variable even if it is set. This forces Emacs to run as if the display were a character terminal.

-batch, -batch

Run Emacs in batch mode, which means that the text being edited is not displayed and the standard terminal interrupt characters such as C-z and C-c continue to have their normal effect. Emacs in batch mode outputs to stderr only what would normally be printed in the echo area under program control.

Batch mode is used for running programs written in Emacs Lisp from shell scripts, makefiles, and so on. Normally the -l option or -f option will be used as well, to invoke a Lisp program to do the batch processing.

-batch implies -q (do not load an init file). It also causes Emacs to kill itself after all command options have been processed. In addition, auto-saving is not done except in buffers for which it has been explicitly requested.

-q, -no-init-file

Do not load your Emacs init file ~/.emacs, or default.el either.


Do not load site-start.el. The options -q, -u and -batch have no effect on the loading of this file--this is the only option that blocks it.

-u user, -user=user

Load user's Emacs init file ~user/.emacs instead of your own.


Enable the Emacs Lisp debugger for errors in the init file.


Set up to do almost everything with single-byte buffers and strings. All buffers and strings are unibyte unless you (or a Lisp program) explicitly ask for a multibyte buffer or string. (Note that Emacs always loads Lisp files in multibyte mode, even if -unibyte is specified; see Section 20.2.) Setting the environment variable EMACS_UNIBYTE has the same effect.


Inhibit the effect of EMACS_UNIBYTE, so that Emacs uses multibyte characters by default, as usual.