integration-sveltekit

Integrate Amplitude analytics into SvelteKit apps with client and server tracking.

28|Updated Dec 5, 2025
One-click install
npx skills add https://github.com/amplitude/wizard --skill integration-sveltekit-amplitude
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: integration-sveltekit
Source: https://github.com/amplitude/wizard/tree/main/skills/integration/integration-sveltekit
Command: npx skills add https://github.com/amplitude/wizard --skill integration-sveltekit-amplitude

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

Streamlines adding Amplitude analytics to SvelteKit projects by providing a structured setup, guidance for client and server-side tracking, and consistent user identification practices.

Core Features & Use Cases

  • Unified SDK workflow: Initialize and configure Amplitude in a SvelteKit project to enable Analytics, Session Replay, and Guides & Surveys.
  • End-to-end integration guidance: Covers client hooks for frontend tracking, server-side events, and best practices for event naming and user properties.
  • Easy reuse of references: Follow the example and reference documents to implement robust instrumentation with minimal code changes.

Quick Start

Install dependencies and run the SvelteKit app to begin the integration using the workflow described in the skill.

Frequently Asked Questions about integration-sveltekit

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I integrate Amplitude analytics into a SvelteKit app?

To integrate Amplitude analytics into a SvelteKit app, use a unified SDK workflow to initialize the client, configure environment variables, and enable features like autocapture and session replay across client and server-side hooks.

What is the best way to track user identity in SvelteKit without exposing PII?

The best way to track user identity in SvelteKit without exposing PII is to follow best practices for consistent user identification, ensuring events use non-sensitive identifiers and align with the example project's structure.

Can I track both client-side and server-side events in SvelteKit with Amplitude?

Yes, you can track both client-side and server-side events in SvelteKit by configuring client hooks for frontend tracking and setting up server-side events within your SvelteKit project environment.

Does the Amplitude unified SDK support autocapture and session replay in SvelteKit?

Yes, the Amplitude unified SDK supports autocapture and session replay in SvelteKit by guiding end-to-end setup and configuration to enable these features within your analytics workflow.

How do I configure environment variables for Amplitude in SvelteKit?

You configure environment variables for Amplitude in SvelteKit by setting up the required API keys in your project environment and referencing them during the unified SDK initialization process.

What limitations exist when using autocapture for SvelteKit event tracking?

When using autocapture for SvelteKit event tracking, limitations include the need to enforce consistent event naming and carefully avoid logging PII in events, requiring alignment with structured reference documents.