Sets the URL to be visited when the add-on is uninstalled. This may be used to clean up server-side data, do analytics, or implement surveys. The URL can be a maximum 255 characters.

This is an asynchronous function that returns a Promise.


var settingUrl = browser.runtime.setUninstallURL(
  url             // string


string. URL to be opened after the add-on is uninstalled. This URL must have an http or https scheme. Set it to an empty string to not open a new tab upon uninstallation.

Return value

A Promise that will be fulfilled with no arguments when the URL has been set, or rejected with an error message if the operation failed.

Browser compatibility

Chrome Edge Firefox Firefox for Android Opera
Basic support Yes No 47.0 48.0 33


function onSetURL() {
  console.log("set uninstall URL");
function onError(error) {
  console.log(`Error: ${error}`);

var settingUrl = browser.runtime.setUninstallURL("");
settingUrl.then(onSetURL, onError);


This API is based on Chromium's chrome.runtime API. This documentation is derived from runtime.json in the Chromium code.

Microsoft Edge compatibility data is supplied by Microsoft Corporation and is included here under the Creative Commons Attribution 3.0 United States License.

Document Tags and Contributors

 Contributors to this page: wbamberg, Makyen, chrisdavidmills
 Last updated by: wbamberg,