So recently i decided to switch to Emacs (btw I am total noob) and began creating my init.el file After downloading doom-modeline package from melpa and following it's installation guide I get an initialization warning:

Warning (initialization): An error occurred while loading ‘/home/telman/.emacs.d/init.el’:
File is missing: Cannot open load file, No such file or directory, doom-modeline

And this is my init.el setup:

(require 'package)
(require 'doom-modeline)
(doom-modeline-mode 1)
(add-to-list 'package-archives '("melpa" . "http://melpa.milkbox.net/packages/") t)
(add-to-list 'custom-theme-load-path "~/.emacs.d/themes")
(load-theme 'dracula t)
(menu-bar-mode -1)
(tool-bar-mode -1)
(toggle-scroll-bar -1)
  • That warning says that he can't find the package doom-modeline. Can you try adding your site-lisp folder to the loadpath? eg. (add-to-list 'load-path "/home/USER/.emacs.d/site-lisp")
    – Swedgin
    May 19, 2020 at 12:36
  • @Swedgin i don't have a site-lisp.Should i create one? May 19, 2020 at 12:40
  • Try the answers first.
    – Swedgin
    May 19, 2020 at 13:02

2 Answers 2


You don't need to (require 'package) and you shouldn't need to (require 'doom-modeline) either. But, depending on your version of Emacs, you need to initialize the package library with (package-initialize) before you can use the packages you installed.

So my crystal ball tells me you should replace the first two lines of your init.el with

  • yeah.that was the case i replaced my "require" lines with (package-initialize) and added (doom-modeline-mode 1) after that May 19, 2020 at 13:16

You are trying to require a package which has not been installed yet. Run

M-x package-install

and then specify


This will install the package so that when you next start emacs, the error should no longer occur.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.