Coding⏱️ 3 min read📅 2026-06-15

How to Fix: Why do downloads that fail with error "NETWORK_FAILED" in firefox have the property "canResume" set to false? How can they be restarted in code?

How to programmatically resume a Firefox download that's failed due to error "NETWORK_FAILED"

Quick Answer: Manually set canResume to true and then use the downloads.resume function with a timeout to attempt to resume the download.

Downloads that fail with an error of 'NETWORK_FAILED' in Firefox can be frustrating, especially when trying to resume them using the WebExtensions API. This issue affects users who rely on extensions or plugins that utilize this feature.

The problem is further compounded by the fact that the `canResume` property of the failed download is set to `false`, preventing the download from being resumed programmatically. However, manually setting `canResume` to `true` has no lasting effect.

⚠️ Common Causes

  • One main reason why this error occurs is due to a network issue that prevents the download from completing successfully. This could be caused by a temporary network connection problem, a slow internet connection, or even a misconfigured network setting.
  • Another possible cause is a firewall or antivirus software blocking the download. In some cases, the download may not have enough bandwidth to complete, leading to a failed download and a `NETWORK_FAILED` error.

🔧 Proven Troubleshooting Steps

Using the WebExtensions API to resume downloads

  1. Step 1: To attempt to resume a download programmatically, use the `downloads.resume` function and pass in the ID of the failed download. This will initiate a new download with the same URL and settings as the original download.
  2. Step 2: Note that even if `canResume` is set to `false`, calling `resume` will not directly cause the download to resume. Instead, it will start a new download, which may or may not be successful depending on the underlying network issue.

Manually setting canResume to true

  1. Step 1: As a workaround, you can manually set `canResume` to `true` using the WebExtensions API. This will update the property value without causing any errors.
  2. Step 2: However, even after setting `canResume` to `true`, the download cannot be resumed programmatically. In this case, clicking the reload icon next to the failed download in the GUI may be the only way to manually resume the download.

🎯 Final Words

While the issue of a `NETWORK_FAILED` error with `canResume` set to `false` can be frustrating, there are steps you can take to attempt to resume downloads programmatically using the WebExtensions API or manually by setting `canResume` to `true`. However, in some cases, manual intervention may still be required.

Did this fix your problem?

If not, try searching for specific error codes.

🔍 Search Error Database

❓ Frequently Asked Questions