-
Push your code to GitHub
git init git add . git commit -m "Initial commit" git branch -M main git remote add origin YOUR_GITHUB_REPO_URL git push -u origin main
-
Deploy on Vercel
- Go to https://vercel.com
- Click "Add New Project"
- Import your GitHub repository
- Vercel will auto-detect Vite settings
- Click "Deploy"
- Done! Your app will be live in ~2 minutes
-
Access from your phone
- Vercel gives you a URL like:
https://scooter-range-tracker.vercel.app - Open this URL on any device
- Add to home screen for app-like experience
- Vercel gives you a URL like:
-
Install Vercel CLI
npm install -g vercel
-
Login to Vercel
vercel login
-
Deploy
vercel
- Follow the prompts
- Accept defaults
- Your app will be deployed!
-
Deploy to production
vercel --prod
Before deploying, make sure you've set up Firebase:
-
Update Firebase Config
- Edit
src/firebase/config.ts - Replace with your actual Firebase credentials
- See
FIREBASE_SETUP.mdfor details
- Edit
-
Firebase Security Rules
- Make sure your Realtime Database rules are set
- See
FIREBASE_SETUP.mdfor the rules
iPhone:
- Open Safari and go to your Vercel URL
- Tap the Share button
- Tap "Add to Home Screen"
- Name it "Scooter Tracker"
- Tap "Add"
Android:
- Open Chrome and go to your Vercel URL
- Tap the menu (3 dots)
- Tap "Add to Home screen"
- Name it "Scooter Tracker"
- Tap "Add"
Share your Vercel URL with anyone who needs to track the same scooter:
- They open the URL
- Enter the same scooter code
- Data syncs across all devices!
Once connected to GitHub:
- Every push to
mainbranch automatically deploys - Preview deployments for pull requests
- Rollback to previous versions anytime
- Go to your Vercel project settings
- Click "Domains"
- Add your custom domain
- Follow DNS setup instructions
Build fails?
- Check that
src/firebase/config.tshas valid Firebase config - Make sure all dependencies are in
package.json - Check build logs in Vercel dashboard
App loads but Firebase doesn't work?
- Verify Firebase config is correct
- Check Firebase Console for errors
- Ensure Realtime Database is enabled
Can't access from phone?
- Make sure you're using the HTTPS URL from Vercel
- Check if phone has internet connection
- Try clearing browser cache
If you want to use environment variables for Firebase:
- In Vercel dashboard, go to Settings → Environment Variables
- Add your Firebase config as variables:
VITE_FIREBASE_API_KEYVITE_FIREBASE_AUTH_DOMAIN- etc.
- Update
src/firebase/config.tsto useimport.meta.env.VITE_* - Redeploy
- Vercel Free Tier: Perfect for this app
- Unlimited deployments
- Automatic HTTPS
- Global CDN
- 100GB bandwidth/month
Need help? Check:
- Vercel Docs: https://vercel.com/docs
- Firebase Docs: https://firebase.google.com/docs