Have started seeing this error after I installed a new version of Emacs. My package code in init file is

(require 'package)
(setq package-archives '(("gnu" . "http://elpa.gnu.org/packages/")
                         ("melpa" . "http://melpa.org/packages/")))

This also fails if I use https. What do I need to do to fix this?

  • This looks correct. Is it still not working? It could be a temporary network issue.
    – Tyler
    Commented Aug 25, 2021 at 13:40
  • Yeah still happening.
    – Andrew
    Commented Aug 25, 2021 at 17:26
  • Can you open the page "melpa.org/packages" in your web browser? This is strange.
    – Tyler
    Commented Aug 27, 2021 at 17:38
  • Yes, I can open it in my browser. package-list-packages gives a bunch of stale links in Emacs, but if I go to Melpa directly in my browser I am able to download the tar files with the correct dates on the links.
    – Andrew
    Commented Aug 27, 2021 at 17:47
  • Starting Emacs from emacs -Q and running your code exactly, I can get package-list-packages to work fine. What version of Emacs are your running? Do you have any other config in your init file? If you do, can you try running just the code you have here? Maybe there's something else in your init that's interacting.
    – Tyler
    Commented Aug 27, 2021 at 18:35

2 Answers 2


Make sure to follow the MELPA Getting started instructions precisely and then read Known Issues sections.

I got the error message "Failed to download ‘MELPA’ archive" on an earlier version of Emacs. In my case, it was fixed at that time by applying described in the Known Issues configuration:

(setq gnutls-algorithm-priority "NORMAL:-VERS-TLS1.3")

Reinstalling Emacs 27.2.2 fixed this. I am not sure why it is working now and did not work before.

  • Are you behind a proxy? Emacs 27.1 has a bug with authenticated proxies.
    – Daniele
    Commented Sep 1, 2021 at 9:01
  • Nope, not behind a proxy
    – Andrew
    Commented Sep 1, 2021 at 17:56

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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