Where Does Element Store Sessions?
Element Desktop session data and config.json paths on Windows, macOS and Linux, and what to wipe for a clean login.
Last updated
Element Desktop is an Electron app, so sessions, encryption keys and caches live in the per OS Electron userData folder under an Element name. A config.json beside them overrides the homeserver and branding for managed installs.
Logging out inside Element keeps caches but drops tokens. For a truly clean slate, quit the app and delete the IndexedDB and Local Storage subfolders. Back up first if you lack key backup, since wiping without recovery phrases loses encrypted history. Mobile apps keep sessions in private storage with no file to browse.
Where Element stores this, by platform
%appdata%\Element
Custom config.json goes directly in this folder. Session databases sit in IndexedDB subfolders. Quit Element fully before copying or deleting anything here.
~/Library/Application Support/Element
Same layout as Windows. Profiles passed with a profile flag append to the folder name. Use Go > Go to Folder to open the hidden Library.
~/.config/Element
Managed config.json also lives here. The message search index sits in an EventStore subfolder that can grow large and is safe to delete to force a rebuild.
Frequently asked questions
How do I fix Element stuck on loading?
Quit Element, back up the Element folder, then delete its IndexedDB and Local Storage contents. Relaunch and log in again. Encrypted rooms need your recovery key to restore history.
Where do I put a custom config.json for Element?
Next to the session data: %appdata%/Element on Windows, ~/.config/Element on Linux, ~/Library/Application Support/Element on Mac. Restart Element after placing it.
Notice an outdated path? Let us know.