From 902ffb3ef5d74f9383e5440ea8ccf05b55f77f46 Mon Sep 17 00:00:00 2001 From: Vercel Date: Sat, 7 Mar 2026 22:57:04 +0000 Subject: [PATCH] Add Vercel Web Analytics setup guide # Vercel Web Analytics Implementation ## Summary Successfully implemented Vercel Web Analytics for the static HTML website tehseenraza.net. ## Changes Made ### Modified Files: - **index.html** - Added Vercel Web Analytics tracking scripts ## Implementation Details Since this is a plain HTML website (no framework like Next.js, React, Vue, etc.), I followed the HTML-specific instructions from the Vercel Web Analytics documentation. ### What was added: 1. **Analytics initialization script** - Added the window.va function that queues analytics events 2. **Vercel Insights script tag** - Added deferred loading of the `/_vercel/insights/script.js` file Both scripts were added to the `` section of index.html, right after the closing `` tag and before the closing `` tag. ## Code Added ```html ``` ## Next Steps To complete the setup: 1. **Enable Web Analytics in Vercel Dashboard:** - Go to your Vercel project dashboard - Click the "Analytics" tab - Click "Enable" to activate Web Analytics - This will add the required routes at `/_vercel/insights/*` on your next deployment 2. **Deploy to Vercel:** - Run `vercel deploy` or push to your connected Git repository - Vercel will automatically deploy your changes 3. **Verify Installation:** - After deployment, visit your website - Open browser DevTools > Network tab - Look for a Fetch/XHR request to `/_vercel/insights/view` - If present, analytics is working correctly 4. **View Analytics Data:** - After users visit your site, go to your Vercel dashboard - Select your project - Click the "Analytics" tab to view visitor data ## Notes - No package installation required for HTML sites - No route support available for plain HTML (unlike framework integrations) - The implementation uses the deferred loading pattern to avoid blocking page rendering - Analytics will only start tracking after Web Analytics is enabled in the Vercel dashboard and the site is deployed Co-authored-by: Vercel --- index.html | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/index.html b/index.html index 465b8ab..a8a18bd 100644 --- a/index.html +++ b/index.html @@ -57,6 +57,10 @@ color: #4b5563; } + +