1. Check your current website connection
This checks the website you are currently visiting, not a different test or preview domain.
2. Back up any existing database first
If you already have real products, customers or orders, do not delete or replace the current D1 database. Keep the same existing database binding when uploading the new ZIP. Ask the person who set up Cloudflare to make a D1 backup before changing anything.
3. Connect permanent database storage (REQUIRED)
- Open Cloudflare Dashboard.
- Open Storage & databases → D1 SQL Database (the menu names may vary). Create a database if you do not already have one.
- Open Workers & Pages → your IrwaStyle Pages project → Settings → Bindings.
- Add a D1 database binding. Set its variable name to exactly
DB(capital letters) and choose the database. - Save, then redeploy your website so the binding is active.
Why? Without DB, changes in the admin panel only appear in the same browser. Orders are deliberately disabled to avoid fake orders.
4. Set your admin password (REQUIRED)
- Open the same Pages project → Settings → Variables and Secrets.
- Add a secret named exactly
ADMIN_PASSWORD. Choose a unique strong password of at least 12 characters. Do not useadmin123. - Add another secret named exactly
SESSION_SECRETand give it a long, random value (32 characters or more). - Save and redeploy. Then visit Admin login, username
admin, password = yourADMIN_PASSWORDsecret.
Keep passwords private. If ADMIN_PASSWORD is configured in Cloudflare, change it there rather than in the website settings screen.
5. Connect photo storage (STRONGLY RECOMMENDED)
- Create an R2 bucket in Cloudflare Storage.
- On the Pages project, open Settings → Bindings → Add R2 bucket.
- Set variable name to exactly
BUCKETand select your bucket. - Save and redeploy. Product photos will then be stored in R2.
If you skip R2, only small compressed images can be uploaded, and photos are stored directly inside the database, which is not ideal as the shop grows.
6. Upload the fixed website ZIP
- In your existing Cloudflare Pages project, create a new Production deployment and upload the provided fixed IrwaStyle ZIP.
- Do not create a new Pages project if you want to keep your existing domain and existing database.
- After deployment, open this page again and tap Check again. It should say LIVE database connected.
Cloudflare Pages supports direct ZIP uploads containing the _worker.js file.
7. Publish a real product and verify
- Open Admin login, then go to Products.
- Replace example images with accurate photographs and enter the real price, available stock and size options.
- Switch Published ON, then press Save product.
- Open the storefront in a private/incognito window or a different phone. The published item should appear. Refresh the page if needed.
- Confirm WhatsApp number, delivery charges, shipping policy, exchange policy and contact details.
Important: New stores start with all sample products hidden because their photos and stock are examples. This protects you from taking orders for items you do not own.
When changes still do not appear
- Confirm that your admin and storefront use the same website domain and the same Cloudflare D1 database.
- Use the Production Pages environment, not a temporary Preview deployment.
- Check that the binding name is exactly
DB. - Refresh the storefront or reopen it after about a minute.
- If the dashboard shows a red connection warning, the server is offline. Do not assume a save worked.
This checklist is for the IrwaStyle Cloudflare Pages direct-upload edition. It does not automatically access or change your Cloudflare account. Keep your secrets out of shared screenshots.