Web Analytics App is a modern, full-stack web application for analyzing and visualizing website performance metrics. It leverages Puppeteer and Lighthouse to provide deep insights into web page speed, user experience, and technical best practices. The app features a clean UI built with React and Tailwind CSS, and a Node.js/Express backend for robust data collection.
- Performance Audits: Analyze any website's speed and core web vitals using Lighthouse.
- Key Metrics: View FCP, LCP, TBT, CLS, TTI, Speed Index, TTFB, and more.
- Visualizations: Interactive charts and summaries for easy understanding.
- Fast Backend: Optimized for quick Lighthouse runs with minimal response size.
- Responsive UI: Built with React and Tailwind CSS for a seamless experience.
- Frontend: React, Tailwind CSS, Vite
- Backend: Node.js, Express, Puppeteer, Lighthouse
web-analytics-app/
├── client/
│ ├── src/
│ │ ├── App.jsx
│ │ ├── PerformanceChart.jsx
│ │ ├── components/ui/
│ │ └── ...
│ ├── public/
│ └── ...
├── server/
│ ├── index.js
│ ├── analyze.js
│ └── ...
├── README.md
├── .gitignore
└── ...
- Node.js (v18+ recommended)
- npm
- Clone the repository:
git clone https://github.com/<your-username>/web-analytics-app.git cd web-analytics-app
- Install dependencies:
cd client npm install cd ../server npm install
- Install Puppeteer Chrome (required for backend):
npx puppeteer browsers install chrome
- Start the backend server:
npm start # or nodemon index.js - Start the frontend (in a new terminal):
cd ../client npm run dev
- Open the frontend in your browser (usually at
http://localhost:5173). - Enter a website URL and click "Analyze Performance".
- View detailed metrics and charts for the analyzed site.
Request:
{
"url": "https://example.com"
}Response:
{
"lighthouseScores": {
"performance": 0.92
},
"metrics": {
"fcp": 1234.56,
"lcp": 2345.67,
"tbt": 89.01,
"cls": 0.02,
"tti": 3456.78,
"speedIndex": 2100.12,
"ttfb": 45.67
}
}- Add more metrics or categories by modifying
server/analyze.js. - Customize UI components in
client/src/components/ui/. - Integrate with databases or authentication as needed.
Pull requests and issues are welcome! Please open an issue to discuss major changes before submitting PRs.
MIT