Deploy your site with Firebase Hosting in 6 easy steps: install the CLI, log in, initialize your project, add files, deploy, and test your live site.

Book a call with an Expert
Starting a new venture? Need to upgrade your web app? RapidDev builds application with your growth in mind.
Step 1: Install Firebase CLI
First, you need to install the Firebase CLI if it isn't already installed. Make sure you have Node.js and npm installed on your machine. Then, run the following command:
npm install -g firebase-tools
Step 2: Log In to Firebase
To use Firebase via the command line, you need to log in to your Firebase account:
firebase login
This command will open a browser window prompting you to log in to your Google account.
Step 3: Initialize Your Project
Navigate to the root of your local project directory and run the following command to initialize Firebase Hosting:
firebase init hosting
During initialization, you will be prompted to select an existing Firebase project or create a new one, choose the public directory that contains your static files, configure as a single-page app if necessary, and set up automatic builds and deploys with GitHub if needed.
Step 4: Add Your Static Files
Ensure your static files (HTML, CSS, JavaScript, assets) are located in the public directory specified during the Firebase initialization process. This is where Firebase will look for files to serve to users.
Step 5: Deploy to Firebase Hosting
Once everything is set up and you have verified that your files are correctly located in the public directory, deploy your site with the following command:
firebase deploy
After deployment, you will receive a unique URL that you can use to access and share your newly deployed site.
Step 6: Test Your Deployment
Visit the URL provided after the deployment to ensure your site is live and working as expected. Test various functionalities to ensure everything is in order. If you run into issues, you can check the deployment logs for debugging.
When it comes to serving you, we sweat the little things. That’s why our work makes a big impact.