---
title: "Wix CMS: Next.js CMS starter"
description: "Next.js template with create-next-app, using Wix Headless for managing content via Wix CMS"
url: "https://vercel.com/templates/next.js/wix-cms"
links:
  repository: "https://github.com/wix/wix-cms-nextjs-template"
  demo: "https://vercel.cms-demo.wix.dev/"
  deploy: "https://vercel.com/new/clone/hidden?demo-title=Education+Starter&demo-description=Education+starter+template+with+Wix%E2%80%99s+Content+Management+solution.&demo-url=https%3A%2F%2Fvercel.cms-demo.wix.dev&project-name=Wix+CMS%3A+Next.js+CMS+starter&repository-name=wix-cms-nextjs-template&repository-url=https%3A%2F%2Fgithub.com%2Fwix%2Fwix-cms-nextjs-template&integration-ids=oac_LZ0wUqGylqzgr8bE8a1R7JTE&skippable-integrations=1&build-command=yarn+build&deploymentIds=dpl_9Gtegfcme9RUmTXFvVGrP8BwDGUV&s=https%3A%2F%2Fgithub.com%2Fwix%2Fwix-cms-nextjs-template&demo-image=%2F%2Fimages.ctfassets.net%2Fe5382hct74si%2F6aerqtuQoSgf2X2jrVs6T%2Fd58dd110e46c4b515042486a52b6671f%2Fwix-thumbnail-cms.jpeg&external-id=%7B%22repo%22%3A%22https%3A%2F%2Fgithub.com%2Fwix%2Fwix-cms-nextjs-template%22%2C%22referralInfo%22%3A%22lp_education%22%7D&referralInfo=lp_education"
---

# Wix CMS: Next.js CMS starter

Next.js template with create-next-app, using Wix Headless for managing content via Wix CMS

# A Wix CMS Next.js Education Template

![Template showcase](https://github.com/wix/wix-cms-nextjs-template/blob/main/docs/media/template-showcase.gif?raw=true)

This template is a [Next.js](https://nextjs.org/) project bootstrapped with [`create-next-app`](https://github.com/vercel/next.js/tree/canary/packages/create-next-app). It uses [Wix Headless](https://dev.wix.com/api/sdk/about-wix-headless/overview) to leverage the Wix CMS business solution for managing the content on an education site.

## Local Development

Prerequisites:

1. [Create a Wix Headless project](https://dev.wix.com/docs/go-headless/getting-started/setup/general-setup/create-a-project)
2. [Add the Content Manager app to your project](https://dev.wix.com/docs/go-headless/getting-started/setup/general-setup/add-apps-to-a-project)
3. Authorize the template with [quick start deployment](https://manage.wix.com/headless-funnel-nextjs/select-platform?templateName=cms) or by [creating an OAuth app](https://dev.wix.com/docs/go-headless/getting-started/setup/authorization/create-an-o-auth-app-for-visitors-and-members)

Set up environment variables to consume Wix Headless APIs:

1. In the template's root folder, create a file for the local environment variables:
    ```sh
    cp .env.template .env.local.
    ```
2. In the new **.env.local** file, paste the OAuth app client ID after `NEXT_PUBLIC_WIX_CLIENT_ID=`.

Run the development server:

1. Run either:

    ```sh
    yarn dev
    ```

    or

    ```sh
    npm i
    npm run dev
    ```

2. Open http://localhost:3000 in your browser to see the template home page.

Edit the template:

- Start editing the homepage by modifying **app/page.tsx**. The page auto-updates as you edit the file.
- Edit any other page using the pattern **app/page.tsx**. For more information, see [Defining Routes](https://beta.nextjs.org/docs/routing/defining-routes) in the Next.js documentation.

# Deployment

You can deploy this repository using any platform which supports Next.js Version 13 and [App Router](https://nextjs.org/docs/app).

The repository requires a single environment variable: `NEXT_PUBLIC_WIX_CLIENT_ID`, which should contain a client ID authorizing access to a Wix project's data.

# Learn More

To learn how to customize the template and add more functionality using Wix APIs, see the [Wix JavaScript SDK reference](https://dev.wix.com/api/sdk).

This template is written in [Next.js](https://nextjs.org/docs) 13 using the [Next.js App Router](https://nextjs.org/docs/app). 

To learn more about Next.js, see:

- [Next.js documentation](https://nextjs.org/docs): Learn about Next.js features and APIs.
- [Learn Next.js](https://nextjs.org/learn): An interactive Next.js tutorial.

Additionally, this template uses the following libraries and features:

- [React Server Components](https://nextjs.org/docs/advanced-features/react-18/server-components)
- [TypeScript](https://www.typescriptlang.org/docs/handbook/release-notes/typescript-4-9.html)
- [TanStack Query v4](https://tanstack.com/query/latest)
- [Tailwind CSS](https://tailwindcss.com/)
- [Flowbite](https://flowbite.com/)
- [Wix client SDK](https://dev.wix.com/api/sdk/introduction)

# Next.js and Wix Integration Guide

See the comprehensive [integration guide](https://github.com/wix/wix-cms-nextjs-template/tree/main/docs/integration-guide.md) for step-by-step instructions on how to configure Wix as your headless Booking solution using Next.js on Vercel.

## Related Templates

### [Wix Bookings: Next.js appointments starter](https://vercel.com/templates/next.js/wix-appointments-subscriptions)

Next.js template, bootstrapped with create-next-app, using Wix Headless for managing appointments via Wix Bookings and Pricing Plans

### [Wix Events and eCommerce Next.js starter](https://vercel.com/templates/next.js/wix-commerce-ticketing)

Next.js template, bootstrapped with create-next-app, using Wix Headless for event ticketing and a store via Wix Events and Stores

### [Wix Bookings: Next.js classes and pricing plans](https://vercel.com/templates/next.js/wix-classes-subscriptions)

Next.js template with create-next-app, using Wix Headless for managing classes and memberships via Wix Bookings and Pricing Plans.

## Related Integrations

### [Wix](https://vercel.com/marketplace/wix)

Integrate with robust business solutions

---

## Additional documentation

The [Vercel Knowledge Base](https://vercel.com/kb) contains guides and answers to common questions about Vercel, including deployment, framework configuration, domains, caching, and troubleshooting.
