What is Sveltekit?
Sveltekit is a full-stack web framework built on top of Svelte that lets you create static sites and server-side-rendered (SSR) apps. It’s designed to be fast with a minimal footprint.
Clone our Sveltekit project
Our Sveltekit starter shows you how to create an example company page with nested routes, dynamic routes, and uses the Contentful GraphQL API to fetch content.
Run the following commands in your terminal to clone our Contentful Sveltekit starter and install dependencies.
Create account and secrets
Create a Contentful account with an empty space. Go to your Contentful space, then
Find your Space ID
Create an access token for the Content Delivery API
Create an access token for the Content Management API
Create environment file
Rename the .env.example at the root of your project to .env
In the new .env file replace
YOUR_SPACE_ID
YOUR_DELIVERY_TOKEN
YOUR_MANAGEMENT_ACCESS_TOKEN
with the values from the previous step.
Import our content model
The project comes with a Contentful set up command that imports the required content model and adds sample content to your space.
Run the following command to import the content model:
Run the project locally
This will start the development server and open the app in a new browser tab.
The page will reload when you make changes.
Deploy
Deploy your project.
For an easy to way to deploy it, use Vercel. Just don't forget to change the repository to your own after you've made changes.



