firebase-hosting-basics

Deploys and configures Firebase Hosting for static sites and single-page apps.

Updated May 5, 2026
One-click install
npx skills add https://github.com/nikegeorgian-stack/otgruzka-tovara --skill firebase-hosting-basics-nikegeorgian-stack
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: firebase-hosting-basics
Source: https://github.com/nikegeorgian-stack/otgruzka-tovara/tree/main/.cursor/skills/firebase-hosting-basics
Command: npx skills add https://github.com/nikegeorgian-stack/otgruzka-tovara --skill firebase-hosting-basics-nikegeorgian-stack

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires firebase-tools, and includes references (resource) components.

What problem does it solve? It guides developers through deploying static websites and SPAs to Firebase Hosting and configuring firebase.json hosting behavior without digging through scattered documentation. ## Core Features & Use Cases - Hosting Configuration: Set up firebase.json with public directories, redirects, rewrites, headers, clean URLs, and trailing slash rules. - Deployment Workflows: Deploy to live sites, create expiring preview channels, and clone preview versions to production. - Local Emulation: Test hosting behavior locally with the Firebase emulator before deploying. - Use Case: You have a React SPA built into a dist folder and want to deploy it with SPA rewrites, test it on a preview channel, then promote it to your live site. ## Quick Start Ask the assistant to deploy your built static site to Firebase Hosting with SPA rewrites configured in firebase.json.

Frequently Asked Questions about firebase-hosting-basics

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I deploy a static site to Firebase Hosting?▼

Run npx firebase-tools deploy --only hosting after setting the public directory in firebase.json. This publishes your files to the default PROJECT_ID.web.app and PROJECT_ID.firebaseapp.com sites on a global CDN.

How do I configure SPA rewrites in firebase.json?▼

Add a rewrites array in the hosting section with source "**" and destination "/index.html". This serves your index.html for all routes, which is required for client-side routing in single-page apps.

Firebase Hosting vs Firebase App Hosting, which should I use?▼

Use Firebase Hosting for static sites and simple SPAs without SSR where you control the build via CLI. Choose App Hosting for full-stack frameworks like Next.js that need server-side rendering and git-push-to-deploy workflows.

How do I test changes before deploying to live Firebase Hosting?▼

Use preview channels with firebase-tools hosting:channel:deploy CHANNEL_ID to get a temporary URL. Channels expire after 7 days by default, and you can clone a preview version to live with hosting:clone.

Can Firebase Hosting serve dynamic content or APIs?▼

Yes, rewrites can route paths to Cloud Functions or Cloud Run services. For example, map /api/** to a function or /container/** to a Cloud Run service with a specified region.