- Fixed database.py - Changed
SUPABASE_KEYtoSUPABASE_ANON_KEY(was causing runtime errors) - Created render.yaml - Proper Render deployment configuration
- Created .env.example - Reference file for environment variables
- CORS enabled - Already configured for all origins (fine for dev, restrict in production)
- Added VITE_API_BASE_URL - Environment variable for dynamic API URL
- Created vercel.json - Proper Vercel deployment configuration
- Created .env.example - Reference file for environment variables
- API client ready - Already supports dynamic API base URL
- Created DEPLOYMENT.md - Complete deployment guide
- Created CHECKLIST.md - This checklist
- Verified .gitignore - .env files are properly ignored
# Terminal 1: Backend
cd backend
pip install -r requirements.txt
uvicorn main:app --host 0.0.0.0 --port 8000
# Terminal 2: Frontend
cd frontend
npm install
npm run dev- Frontend .env has
VITE_API_BASE_URL(for local:http://localhost:8000) - Backend .env has
SUPABASE_URLandSUPABASE_ANON_KEY
- Login/Register works
- Dashboard loads data
- Forecast page displays chart (fixed!)
- Transactions page works
- Invoices page works
- Decisions page works
git add .
git commit -m "Add deployment configuration (vercel.json, render.yaml, DEPLOYMENT.md)"
git push origin main- Go to https://render.com
- New → Web Service
- Connect GitHub repo
- Configure:
- Service name:
finguard-backend - Environment:
Python - Build command:
pip install -r requirements.txt - Start command:
uvicorn main:app --host 0.0.0.0 --port 8000 - Root directory:
backend
- Service name:
- Environment variables (copy from
.env.example):SUPABASE_URLSUPABASE_ANON_KEYOPENAI_API_KEY(if needed)
- Deploy and wait for the URL (e.g.,
https://finguard-backend.onrender.com)
- Go to https://vercel.com
- New Project
- Import GitHub repo
- Configure:
- Framework:
Vite - Build command:
npm run build - Output directory:
frontend/dist - Root directory:
frontend
- Framework:
- Environment variables:
VITE_SUPABASE_URL:https://ccuaybxdgtyvbpegockf.supabase.coVITE_SUPABASE_ANON_KEY: (from your .env)VITE_API_BASE_URL: (use Render backend URL from Step 2)
- Deploy
After getting Vercel URL, update backend/main.py:
allow_origins=[
"https://your-vercel-url.vercel.app",
"http://localhost:3000",
],- Backend health check:
GET /api/healthreturns 200 - Frontend loads without errors
- Can log in and see data
- API calls work (check browser DevTools Network)
| Issue | Solution |
|---|---|
| "Cannot reach API" | Verify VITE_API_BASE_URL in Vercel env vars matches Render URL |
| Backend 500 errors | Check Render logs, verify env vars are set correctly |
| Frontend won't build | Ensure root directory is frontend in Vercel, run npm run build locally first |
| Supabase auth fails | Verify VITE_SUPABASE_* keys in Vercel match your Supabase project |
| Render won't build | Check Python version, try running locally: pip install -r requirements.txt |
backend/database.py- Fixed Supabase key variablefrontend/.env- Added VITE_API_BASE_URLbackend/.env.example- NEWfrontend/.env.example- NEWvercel.json- NEWrender.yaml- NEWDEPLOYMENT.md- NEWCHECKLIST.md- NEW (this file)
All deployment-blocking issues have been fixed. You're ready to deploy!