You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
v5.1.0 requires firebaseextensions.googleapis.com when Extensions are unused in a project #1596
After updating firebase-functions from 5.0.1 to 5.1.0, deploying no longer works.
[REQUIRED] Expected behavior
Successful deploy.
[REQUIRED] Actual behavior
I now get an error that the Extensions API isn't enabled, even though it's unused by the project.
[2024-08-19T22:29:41.411Z] >>> [apiv2][query] GET https://firebaseextensions.googleapis.com/v1beta/projects/XXXXX/instances pageSize=100&pageToken=
[2024-08-19T22:29:41.624Z] <<< [apiv2][status] GET https://firebaseextensions.googleapis.com/v1beta/projects/XXXXX/instances 403
[2024-08-19T22:29:41.624Z] <<< [apiv2][body] GET https://firebaseextensions.googleapis.com/v1beta/projects/XXXXX/instances {"error":{"code":403,"message":"Firebase Extensions API has not been used in project XXXXX before or it is disabled. Enable it by visiting https://console.developers.google.com/apis/api/firebaseextensions.googleapis.com/overview?project=XXXXX then retry. If you enabled this API recently, wait a few minutes for the action to propagate to our systems and retry.","status":"PERMISSION_DENIED","details":[{"@type":"type.googleapis.com/google.rpc.Help","links":[{"description":"Google developers console API activation","url":"https://console.developers.google.com/apis/api/firebaseextensions.googleapis.com/overview?project=XXXXX"}]},{"@type":"type.googleapis.com/google.rpc.ErrorInfo","reason":"SERVICE_DISABLED","domain":"googleapis.com","metadata":{"service":"firebaseextensions.googleapis.com","consumer":"projects/XXXXX"}}]}}
Were you able to successfully deploy your functions?
When I'm deploying locally, I see that issue above.
When I deploy via GH Action, I actually get a different API that isn't enabled (I assume because it's deploying with a workload identity instead):
Error: HTTP Error: 403, Cloud Billing API has not been used in project XXXXX before or it is disabled. Enable it by visiting https://console.developers.google.com/apis/api/cloudbilling.googleapis.com/overview?project=XXXXX then retry. If you enabled this API recently, wait a few minutes for the action to propagate to our systems and retry.
changed the title [-]v5.1.0 requires Extensions API when Extensions are unused in a project[/-][+]v5.1.0 requires firebaseextensions.googleapis.com when Extensions are unused in a project[/+]on Aug 19, 2024
I'm getting the firebaseextensions.googleapis.com and cloudbilling.googleapis.com errors in my ci with the following dependencies. From some other issues it sounds like this is normal and expected now?
This means that when we deploy functions we will always be checking if you have extension instances in your project that were defined using an autogenerated SDK in a deploying codebase. So we need to list the current extension instances in your project to determine if there is anything to potentially delete or configure or update.
Consider enabling the Firebase Extensions Viewer permission which includes the ability to list extension instances.
Reacted by James Yoo, Mark Carlton, David Guyon, kushagra Agarwal and Jürgen Kozyrev
This was helpful context -- I initially understood the function deployment failures as a regression in the firebase-functions dependency because our codebase is not leveraging extensions, and so the error messages during deployment were not easily understood. Even though I intuited the potential solution of adding the stated Firebase Extensions Viewer role to our deployment service account, the reasons behind doing so were unclear and I was hesitant to do so.
Couldn't we mitigate these errors in projects where the Extensions api is not explicitly enabled? (e.g. in such projects, the extension api not being enabled can signal that there's no need for the features checking against existing extensions, or installing extension instances defined in the codebase)
Otherwise a more detailed error message during deployment explaining the above could help out. Docs don't seem to be up to date in this regard
They apparently posted a faulty update to the CLI in the last few hours that politely checked the Extensions API worldwide, blocking deployments globally with this false "Error 403".
Can confirm this issue is happening as well. Been deploying for two weeks. No changes. Randomly getting this 403 despite being an Owner with every possible thing done. Signing out. Signing back in. Disabling and Reenabling Extenstions API, etc.
It seems the only solution may be to manually patch the buggy CLI to allow it to skip this useless check it's doing. Most of us have no use for Extenstions at all yet it still forces this check.
i extensions: ensuring required API firebaseextensions.googleapis.com is enabled...
Which then blocks us from deploying due to Googles bug despite us not even using Extenstions due to this well known bug so we shouldn't be forced to suffer those bugs...
[2026-02-26T23:44:23.379Z] Error Context: { "body": { "error": { "code": 403, "message": "The caller does not have permission", "status": "PERMISSION_DENIED" } }, "response": { "statusCode": 403 } }
EDIT: I spent two hours troubleshooting. The fix is actually easy and takes 5min to enable a feature Google should have done before since Extenstions check is useless for us without them. All you have to do is manually patch the buggy CLI to allow you to skip the useless extenstions check.
Fix for Firebase CLI Extensions API 403 Error
Issue: Firebase CLI v14+ requires Extensions API permissions during deployment, even if you're not using Firebase Extensions. This causes a 403 error whenever Google decides to introduce a bug.
Workaround: Patch the Firebase CLI to skip the Extensions API check.
Step 1: Find your Firebase CLI installation npm root -g
This will output something like: /home/username/.nvm/versions/node/v20.9.0/lib/node_modules
Step 2: Edit the prepare.js file
Open this file in your editor: <npm-root-from-step-1>/firebase-tools/lib/deploy/extensions/prepare.js
Also came back to suggest a work around. After some exploration with Claude we just early returned prepare and prepareDynamicExtensions directly and am able to deploy function. Claude says:
In node_modules/firebase-tools/lib/deploy/extensions/prepare.js, two functions were patched with early returns:
prepare (line 140) — runs when extensions is in the deploy target list. Checks extensions API is enabled, verifies firebaseextensions.instances.list permission, then diffs what extensions you want vs have.
prepareDynamicExtensions (line 120) — called from the functions deploy path if any function build references extensions. Does the same API/permission checks before processing dynamic extension configs.
Both hit the firebaseextensions.googleapis.com/v1beta/projects/{id}/instances endpoint which is currently returning 403 across many projects due to a Google-side issue (#1596). The patch is safe since you don't use extensions — these functions do nothing useful for your project. Note that npm install -g firebase-tools will overwrite the patch.
On Fri, 27 Feb 2026, 9:52 am Ryan, ***@***.***> wrote:
*RyanCarrier* left a comment (firebase/firebase-functions#1596)
<#1596 (comment)>
Here is the temporary patch as a CI step
- name: Patch firebase-tools extensions check (temp workaround)
shell: bash
run: |
# Workaround for #1596
# Firebase CLI 403 on Extensions API - skip check since we don't use extensions
PREPARE_JS="$(npm root -g)/firebase-tools/lib/deploy/extensions/prepare.js"
SED="sed"; [[ "$OSTYPE" == darwin* ]] && SED="gsed"
$SED -i \
-e 's|await (0, extensionsHelper_1.ensureExtensionsApiEnabled)(options);|//await (0, extensionsHelper_1.ensureExtensionsApiEnabled)(options);|g' \
-e 's|await (0, requirePermissions_1.requirePermissions)(options, \["firebaseextensions.instances.list"\]);|//await (0, requirePermissions_1.requirePermissions)(options, ["firebaseextensions.instances.list"]);|g' \
-e 's|let haveExtensions = await planner.haveDynamic(projectId);|let haveExtensions = [];|g' \
-e 's|const haveExtensions = await planner.have(projectId);|const haveExtensions = [];|g' \
"$PREPARE_JS"
—
Reply to this email directly, view it on GitHub
<#1596 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AJL4UPHZOPPLCHO7RNYZ6DL4N7A7NAVCNFSM6AAAAACOCVPBNOVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZTSNZQGY3TGMJXHE>
.
You are receiving this because you commented.Message ID:
***@***.***>
Activity
bkendall commentedon Aug 19, 2024
When I'm deploying locally, I see that issue above.
When I deploy via GH Action, I actually get a different API that isn't enabled (I assume because it's deploying with a workload identity instead):
[-]v5.1.0 requires Extensions API when Extensions are unused in a project[/-][+]v5.1.0 requires firebaseextensions.googleapis.com when Extensions are unused in a project[/+]bkendall commentedon Aug 20, 2024
Thanks for the fix!
ifielker commentedon Aug 20, 2024
You're welcome :)
CarltonK commentedon Aug 21, 2024
Updating firebase-tools to the latest version worked for me
13.15.3
steveoh commentedon Oct 1, 2024
I'm getting the firebaseextensions.googleapis.com and cloudbilling.googleapis.com errors in my ci with the following dependencies. From some other issues it sounds like this is normal and expected now?
├── [email protected]
├── [email protected]
Schmale97 commentedon Nov 12, 2024
This looks to have been re-introduced, currently getting the error for
[email protected]
[email protected]
delebakare commentedon Nov 14, 2024
Worked for me with [email protected] and [email protected]
ixjamesyoo commentedon Nov 14, 2024
Can confirm the issue was re-introduced on my end as well.
[email protected] [email protected]
Reverted [email protected], and deployment worked fine again
ifielker commentedon Nov 14, 2024
The firebaseextensions.instance.list permission is now required for any firebase deploy that includes functions. This is expected. It is because we have launched new features that allow you to define extension instances in your functions codebase and deploy them that way. See https://firebase.google.com/docs/extensions/install-extensions?interface=sdk) for details.
This means that when we deploy functions we will always be checking if you have extension instances in your project that were defined using an autogenerated SDK in a deploying codebase. So we need to list the current extension instances in your project to determine if there is anything to potentially delete or configure or update.
Consider enabling the Firebase Extensions Viewer permission which includes the ability to list extension instances.
ixjamesyoo commentedon Nov 14, 2024
@ifielker Thanks for the quick response.
This was helpful context -- I initially understood the function deployment failures as a regression in the
firebase-functionsdependency because our codebase is not leveraging extensions, and so the error messages during deployment were not easily understood. Even though I intuited the potential solution of adding the stated Firebase Extensions Viewer role to our deployment service account, the reasons behind doing so were unclear and I was hesitant to do so.Couldn't we mitigate these errors in projects where the Extensions api is not explicitly enabled? (e.g. in such projects, the extension api not being enabled can signal that there's no need for the features checking against existing extensions, or installing extension instances defined in the codebase)
Otherwise a more detailed error message during deployment explaining the above could help out. Docs don't seem to be up to date in this regard
ArjunIsCool commentedon Dec 4, 2025
Is there some way to circumvent this error without having to grant extension permissions? Sorry for necro.
bdlgq-mike commentedon Feb 26, 2026
I am getting this error today, no changes to my setup. it was working, then all of a sudden i was getting the
Error: Request to https://firebaseextensions.googleapis.com/v1beta/projects/XXXXXXX/instances?pageSize=100&pageToken= had HTTP Error: 403, The caller does not have permission
5 remaining items
EIleven commentedon Feb 26, 2026
Same here, seems to be a general problem
m-rios commentedon Feb 26, 2026
mee too 🙄
EIleven commentedon Feb 26, 2026
They apparently posted a faulty update to the CLI in the last few hours that politely checked the Extensions API worldwide, blocking deployments globally with this false "Error 403".
dnathe4th commentedon Feb 27, 2026
Thumbs up if claude sent you here
EIleven commentedon Feb 27, 2026
I literally had to search GitHub/Stack Overflow, like the old-timers did.
stefon-rentor commentedon Feb 27, 2026
Can confirm this issue is happening as well. Been deploying for two weeks. No changes. Randomly getting this 403 despite being an Owner with every possible thing done. Signing out. Signing back in. Disabling and Reenabling Extenstions API, etc.
It seems the only solution may be to manually patch the buggy CLI to allow it to skip this useless check it's doing. Most of us have no use for Extenstions at all yet it still forces this check.
i extensions: ensuring required API firebaseextensions.googleapis.com is enabled...Which then blocks us from deploying due to Googles bug despite us not even using Extenstions due to this well known bug so we shouldn't be forced to suffer those bugs...
[2026-02-26T23:44:23.379Z] Error Context: { "body": { "error": { "code": 403, "message": "The caller does not have permission", "status": "PERMISSION_DENIED" } }, "response": { "statusCode": 403 } }EDIT: I spent two hours troubleshooting. The fix is actually easy and takes 5min to enable a feature Google should have done before since Extenstions check is useless for us without them. All you have to do is manually patch the buggy CLI to allow you to skip the useless extenstions check.
Fix for Firebase CLI Extensions API 403 Error
Issue: Firebase CLI v14+ requires Extensions API permissions during deployment, even if you're not using Firebase Extensions. This causes a 403 error whenever Google decides to introduce a bug.
Workaround: Patch the Firebase CLI to skip the Extensions API check.
Step 1: Find your Firebase CLI installation
npm root -gThis will output something like:
/home/username/.nvm/versions/node/v20.9.0/lib/node_modulesStep 2: Edit the prepare.js file
Open this file in your editor:
<npm-root-from-step-1>/firebase-tools/lib/deploy/extensions/prepare.jsStep 3: Apply the patches
Patch 1 (around line 125-129):
Patch 2 (around line 146-148):
Patch 3 (around line 155-156):
dnathe4th commentedon Feb 27, 2026
Also came back to suggest a work around. After some exploration with Claude we just early returned
prepareandprepareDynamicExtensionsdirectly and am able to deploy function. Claude says:gunnarmein-ts commentedon Feb 27, 2026
I have the same issue. I don't see how the workaround will work for our GitHub-based deployment.
gunnarmein-ts commentedon Feb 27, 2026
@ifielker (the only name I see here) can we get this reopened?
Andrew-Hopkins-Akcelo commentedon Feb 27, 2026
@stefon-rentor 's workaround succeeded for me, allowing me to manually deploy the functions.
Note: You will want to apply this update to either your global firebase-tools install, or your applications firebase-tools module itself
Here's a terminal command you can run to apply stefon's workaround
You will want to run this from either
/home/<username>/.nvm/versions/node/<INSERT NODE VERSION>/lib/node_modules/firebase-tools( Global Install )webapp-root/node_modules/firebase-tools/( Local Application Install )Note:
aderderian commentedon Feb 27, 2026
Still happening for me right now
risalfajar commentedon Feb 27, 2026
Seems like a regression, please reopen @bkendall
RyanCarrier commentedon Feb 27, 2026
Here is the temporary patch as a CI step
ArjunIsCool commentedon Feb 27, 2026
qlereboursFR commentedon Feb 27, 2026
According to this comment, this is fixed. It's working for me now