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
    Aug 25, 2021 at 13:40
  • Yeah still happening.
    – Andrew
    Aug 25, 2021 at 17:26
  • Can you open the page "melpa.org/packages" in your web browser? This is strange.
    – Tyler
    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
    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
    Aug 27, 2021 at 18:35

2 Answers 2


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
    Sep 1, 2021 at 9:01
  • Nope, not behind a proxy
    – Andrew
    Sep 1, 2021 at 17:56

For those who still experience the issue:

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

I personally had the questioned error message "Failed to download ‘MELPA’ archive" on an earlier version of Emacs. For me it was fixed at that time by the described in the Known Issues configuration:

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

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.