Skip to main content

Deploying Cloud Functions From a Local Computer

In rare cases, there might be an issue with the FlutterFlow onboard code analyser for cloud functions. A workaround that can help deploy your custom cloud functions is to do so manually from your local computer to Firebase.

Danny avatar
Written by Danny
Updated yesterday

Below are the steps and guidelines when deploying your application to Firebase from your local computer.

Local Deployment Steps

1. Download the Flutterflow Project

Download your project from FlutterFlow to your local computer.

2. Locate the Custom Cloud Functions Folder

In your project’s file structure, you should see a directory that contains all the custom cloud functions.

Open your IDE terminal and navigate to it:

cd firebase/custom_cloud_functions

3. Ensure Node.js and npm Are Installed

Make sure you have Node.js and npm installed on your computer.

Follow this guide: Node.js Installation Guide to install Node.js if it is missing in your computer.

4. Install Dependencies

Once Node.js and npm are set up, run:

npm install


This installs all third-party packages that your cloud functions use, as defined in the package.json file.

This step is crucial because it helps identify any missing or broken dependencies before deployment.

5. Log in to Firebase from Terminal

Install Firebase tools globally: To access Firebase locally you are required to login via the firebase CI tools, this you access to firebase projects from the command line.

sudo npm install -g firebase-tools


Enter your computer password when prompted.

Then, log in to Firebase:

firebase login

A browser window will open—complete the authentication using the email associated with your Firebase project.

6. Initialize Firebase in Your Project

Confirm that your terminal is in the same directory as the index.js and package.json files, then run:

firebase init


When prompted:

  • Use the arrow keys to select Functions: Configure a Cloud Functions directory and its files


  • Choose Use existing project

  • From the list presented, select the Firebase project linked to your FlutterFlow project

  • After that, select the custom_cloud_functions

  • Select Overwrite

  • Select JavaScript as the language

  • For ESLint setup, type n and press Enter

  • For Files overwrite, select No - this prevents the compiler from erasing your already existing cloud functions that are in your FlutterFlow project.

  • When asked to install dependencies, type y and press Enter

7. Deploy to Firebase

Once everything is ready, deploy your functions:

firebase deploy --only functions

This will start the deployment process for your cloud functions.

Firebase deploy —only functions - This command deploys all functions defined in your functions directory to your Firebase project.

If you want to deploy a specific cloud ``function you can use,

firebase deploy --only functions:cloudFunctionName1,functions:cloudFunctionName2

8. If You Encounter Errors

If you face issues during deployment, check your firebase.json file.


Remove any codebase definitions for unused or old cloud functions, leaving only the relevant ones.

This should be the correct JSON for this specific deployment.


Then rerun: - firebase deploy --only functions or firebase deploy --only functions:cloudFunctionName1,functions:cloudFunctionName2

firebase deploy --only functions

If prompted to delete existing cloud functions, select No to prevent deletion. This prevents the CLI from deleting the current deployed cloud function already existing in Firebase.

9. Wait for Deployment

Wait for Firebase to complete the deployment process. Once done, your cloud functions should be successfully deployed and ready to use.



More Resources On Deploying Cloud Functions

Did this answer your question?