PluginBench
Skill
Official
Review
Audit score 70

firebase-hosting-basics

firebase/agent-skills

Deploy static web apps, SPAs, and microservices to Firebase Hosting with a single command.

What is firebase-hosting-basics?

Firebase Hosting (Classic) is a fast, secure hosting service for static sites, Single Page Apps, and simple microservices. Use this skill when deploying web content to a global CDN with zero-configuration SSL and preview channels—not for full-stack frameworks requiring server-side rendering.

  • Deploy static sites and SPAs to a global CDN with SSD caching at edge locations
  • Automatic SSL/TLS encryption with zero configuration required
  • Create temporary preview channels to test changes before going live
  • Integrate with GitHub Actions for automated previews and deployments
  • Serve dynamic content using Cloud Functions or Cloud Run backends
  • Configure redirects, rewrites, headers, and public directories via firebase.json

How to install firebase-hosting-basics

npx skills add https://github.com/firebase/agent-skills --skill firebase-hosting-basics
Prerequisites
  • Firebase project created and initialized
  • firebase-tools CLI installed (npx firebase-tools@latest)
  • Static build output or SPA ready to deploy
Claude Code
Cursor
Windsurf
Cline

How to use firebase-hosting-basics

  1. 1.Initialize Firebase in your project directory with `firebase init hosting`
  2. 2.Configure your public directory and deployment settings in firebase.json
  3. 3.Build your app (if needed) to generate static output
  4. 4.Run `firebase deploy` to deploy to production
  5. 5.Optionally create preview channels with `firebase hosting:channel:deploy` for testing before going live
  6. 6.Use `firebase emulators:start --only hosting` to test locally at http://localhost:5000

Use cases

Good for
  • Deploying a React or Vue SPA to production
  • Publishing a static HTML/CSS/JS website with global CDN distribution
  • Setting up preview URLs for team review before merging to main
  • Automating deployments on every GitHub push using Actions
  • Hosting a simple microservice alongside static assets
Who it's for
  • Frontend developers deploying SPAs
  • Web developers publishing static sites
  • Teams using GitHub for version control and CI/CD
  • Developers wanting fast, secure hosting without infrastructure management

firebase-hosting-basics FAQ

Should I use Firebase Hosting or Firebase App Hosting?

Use Firebase Hosting (Classic) for static sites and simple SPAs without server-side rendering. Use Firebase App Hosting for full-stack frameworks like Next.js or Angular that require SSR or ISR.

How do I test my site before deploying to production?

Use preview channels to deploy to temporary URLs for testing, or run `firebase emulators:start --only hosting` to test locally at http://localhost:5000.

Can I serve dynamic content with Firebase Hosting?

Yes, you can serve dynamic content and microservices by integrating Cloud Functions or Cloud Run backends with your Hosting configuration.

Is SSL/TLS encryption included?

Yes, Firebase Hosting includes zero-configuration SSL/TLS encryption by default for all sites.

Can I automate deployments with GitHub?

Yes, Firebase Hosting integrates with GitHub Actions to automatically create preview channels and deploy on push.

Full instructions (SKILL.md)

Source of truth, from firebase/agent-skills.


name: firebase-hosting-basics description: Skill for working with Firebase Hosting (Classic). Use this when you want to deploy static web apps, Single Page Apps (SPAs), or simple microservices. Do NOT use for Firebase App Hosting.

hosting-basics

This skill provides instructions and references for working with Firebase Hosting, a fast and secure hosting service for your web app, static and dynamic content, and microservices.

Overview

Firebase Hosting provides production-grade web content hosting for developers. With a single command, you can deploy web apps and serve both static and dynamic content to a global CDN (content delivery network).

Key Features:

  • Fast Content Delivery: Files are cached on SSDs at CDN edges around the world.
  • Secure by Default: Zero-configuration SSL is built-in.
  • Preview Channels: View and test changes on temporary preview URLs before deploying live.
  • GitHub Integration: Automate previews and deploys with GitHub Actions.
  • Dynamic Content: Serve dynamic content and microservices using Cloud Functions or Cloud Run.

Hosting vs App Hosting

Choose Firebase Hosting if:

  • You are deploying a static site (HTML/CSS/JS).
  • You are deploying a simple SPA (React, Vue, etc. without SSR).
  • You want full control over the build and deploy process via CLI.

Choose Firebase App Hosting if:

  • You are using a supported full-stack framework like Next.js or Angular.
  • You need Server-Side Rendering (SSR) or ISR.
  • You want an automated "git push to deploy" workflow with zero configuration.

Instructions

1. Configuration (firebase.json)

For details on configuring Hosting behavior, including public directories, redirects, rewrites, and headers, see configuration.md.

2. Deploying

For instructions on deploying your site, using preview channels, and managing releases, see deploying.md.

3. Emulation

To test your app locally:

npx -y firebase-tools@latest emulators:start --only hosting

This serves your app at http://localhost:5000 by default.