Web SDK
Track events and web vitals in your website
Web Analytics is not yet publicly available
Use the FastStats Web SDK to track page activity, custom events, and performance data in your web app.
Installation
npm i faststatsInitialize
import { initFastStats } from "@faststats/web";
initFastStats({
projectId: "your-project-id",
webVitals: true,
cookieless: true,
});Script Tag Alternative
<script
defer
data-project-id="your-project-id"
data-web-vitals="true"
data-cookieless="true"
src="https://cdn.faststats.dev/tracker.js"
></script>Core Metrics
LCPfor loading performanceCLSfor visual stabilityINPfor responsivenessFCPfor first content paintTTFBfor server response speed
Notes
- Enable Web Vitals in project settings to receive vitals data.
cookielessmode is suitable for privacy-focused deployments.- Start with default sampling and tune only if traffic is very high.