Where Is the LyX User Directory?
Where LyX keeps its user directory, preferences and layouts.
Last updated
LyX centers on a user directory with preferences, layouts, templates and keymaps: ~/.lyx on Unix, versioned Application Support on Mac, Roaming lyx on Windows installs. Files here override the system library directory.
The preferences file records Tools Preferences choices while session tracks window state. Custom classes belong in layouts with a reconfigure after. Keep user files out of the program tree or upgrades wipe them.
Where LyX stores this, by platform
~/.lyx/
Holds preferences, session, layouts and templates. User files override the system library dir. Relocate with -userdir flag. Custom .layout files go in layouts with Tools, Reconfigure after.
%APPDATA%\lyx\
Same user directory role under Roaming AppData on all user installs. Keep custom layouts and modules here, never in Program Files. Back up the folder before major version jumps.
Frequently asked questions
How do I install a custom LyX layout?
Drop the .layout file into the layouts child of your user directory and run Tools, Reconfigure, then restart. Document Settings then lists the new class for selection.
Can I relocate the LyX user directory?
Pass -userdir or set the versioned LYX_USERDIR variable. The man page documents the precedence: flag first, variable second, default home path last.
Notice an outdated path? Let us know.