# Migrate Chrome extension to Mozilla Addon

**URL:** <https://discourse.mozilla.org/t/migrate-chrome-extension-to-mozilla-addon/105261>\
**Category:** Development\
**Tags:** learning\
**Created:** [September 9, 2022, 6:14am UTC](https://discourse.mozilla.org/t/migrate-chrome-extension-to-mozilla-addon/105261 "2022-09-09T06:14:57Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![anjanesh](https://sea1.discourse-cdn.com/flex001/user_avatar/discourse.mozilla.org/anjanesh/32/51735_2.png) [@anjanesh](https://discourse.mozilla.org/u/anjanesh)\
**Post date:** [September 9, 2022, 6:14am UTC](https://discourse.mozilla.org/t/migrate-chrome-extension-to-mozilla-addon/105261/1 "2022-09-09T06:14:58Z")

</div>

I just got started in Chrome extension development and got it published in the Chrome store and Edge marketplace.

Why isn’t the same code not getting accepted at Mozilla Addons ? manifest\_version is 3, which Mozilla says should be 2 - but the upload fails even if I change to 2.

What should I be looking for, for FireFox specific addon development ?

---

<div class="post-metadata">

**Author:** ![juraj.masiar](https://sea1.discourse-cdn.com/flex001/user_avatar/discourse.mozilla.org/juraj.masiar/32/30587_2.png) [@juraj.masiar](https://discourse.mozilla.org/u/juraj.masiar)\
**Post date:** [September 9, 2022, 9:06am UTC](https://discourse.mozilla.org/t/migrate-chrome-extension-to-mozilla-addon/105261/2 "2022-09-09T09:06:07Z")

</div>

Well, this is a very unfortunate time to migrate Chrome/Edge extension to Firefox.  
Chrome now requires Manifest V3, but Firefox only supports V2. The V3 support should come [by the end of the year](https://blog.mozilla.org/addons/2022/05/18/manifest-v3-in-firefox-recap-next-steps/) though.

Also, there are some big differences between V2/V3, so unless you are releasing “hello world” extension 🙂 , there is only a small chance the Chrome extension will work in Firefox simply by changing Manifest file.

You need to study MV2 and make a changes to your manifest file and then depending on the API you use, make changes there.

**See the MV2/3 changes here:**  
[https://developer.chrome.com/docs/extensions/mv3/intro/mv3-migration/](https://developer.chrome.com/docs/extensions/mv3/intro/mv3-migration/)

Alternatively, you can wait a few months till Firefox finishes MV3 support.

---

<div class="post-metadata">

**Author:** ![anjanesh](https://sea1.discourse-cdn.com/flex001/user_avatar/discourse.mozilla.org/anjanesh/32/51735_2.png) [@anjanesh](https://discourse.mozilla.org/u/anjanesh)\
**Post date:** [September 9, 2022, 10:28am UTC](https://discourse.mozilla.org/t/migrate-chrome-extension-to-mozilla-addon/105261/3 "2022-09-09T10:28:22Z")

</div>

Well - I guess I’ll wait for end of year update from FireFox - that’s not far away.  
I just don’t want to have a separate code base for FireFox.  
I am also making use of `chrome.storage` so I guess I would still have to do

```auto
var browser = (window.browser)? window.browser : window.chrome;

```

when Mozilla launches MV3 ?

---

<div class="post-metadata">

**Author:** ![juraj.masiar](https://sea1.discourse-cdn.com/flex001/user_avatar/discourse.mozilla.org/juraj.masiar/32/30587_2.png) [@juraj.masiar](https://discourse.mozilla.org/u/juraj.masiar)\
**Post date:** [September 9, 2022, 11:38am UTC](https://discourse.mozilla.org/t/migrate-chrome-extension-to-mozilla-addon/105261/4 "2022-09-09T11:38:08Z")

</div>

Firefox supports also “chrome” namespace so no need to use hacks like that 🙂.  
Once they have MV3 support, most things should work without any change.

But there is a chance you will still need to use a different manifest file since Chrome uses Service workers and Firefox will initially support only event pages (which is almost the same thing). So to simplify your build process, you may need a simple “build script” that will copy all files from your “src” folder into some “firefox\_dist” folder and then replace the manifest file with Firefox specific one.

Anyway, there is no timeline yet (apart from “by the end of this year”), but there will be for sure article about it here:  
[https://blog.mozilla.org/addons/](https://blog.mozilla.org/addons/)
