# Firebase Console checklist (arafstore-14938)

Complete these in [Firebase Console](https://console.firebase.google.com/project/arafstore-14938) before go-live.

## 1. Realtime Database

- [ ] **Build → Realtime Database → Create database**
- [ ] Region: **United States** (default)
- [ ] Database URL must be: `https://arafstore-14938-default-rtdb.firebaseio.com`
- [ ] Matches [`firebase-config.js`](firebase-config.js) `databaseURL`

## 2. Authentication

- [ ] **Build → Authentication → Sign-in method**
- [ ] Enable **Email/Password**

## 3. Authorized domains

- [ ] **Authentication → Settings → Authorized domains**
- [ ] Add your production domain (e.g. `yourstore.com`)
- [ ] Keep `localhost` for local dev

## 4. RTDB security rules

- [ ] **Realtime Database → Rules**
- [ ] Paste contents of repo [`database.rules.json`](database.rules.json)
- [ ] Click **Publish**

Or from repo root (if Firebase CLI installed and logged in):

```bash
firebase login
firebase deploy --only database
```

## 5. Analytics (optional)

- [ ] Already in config: `measurementId: G-14S76QK4CM`

## After Console setup

1. Run local: `.\scripts\verify-firebase-config-consistency.ps1`
2. Upload: `.\scripts\prepare-production-upload.ps1` → use `deploy/firebase-server-files.zip`
3. On server: `php api/firebase-smoke-test.php` → expect `OK`
4. Test signup at your site, then store setup wizard
