Set Up Headless Turbo Theme
This guide connects the Headless Turbo theme to a Fynd Commerce sales channel and starts the local storefront.
Review Prerequisites
- Git
- Node.js 20 or later
- A Fynd Commerce company and sales channel
- The sales channel's application ID and public-scope application token
Set Up Headless Turbo Theme
-
Clone the Headless Turbo theme repository:
git clone https://github.com/gofynd/HeadlessTurbo.git
cd HeadlessTurbo -
Install dependencies with your preferred package manager.
-
Create or update the env file with the required environment variables:
PROXY_TARGET=https://api.fynd.com
DOMAIN=api.fynd.com
PORT=8080
APPLICATION_ID=your_application_id
APPLICATION_TOKEN=your_public_application_token
TURBO_DEV_PORT=5002
USE_PROXY=truewarningThe token is injected into the storefront and can be read by visitors. Use only a public-scope application token.
-
Start the Webpack Dev Server and Fastify using your selected package manager.
-
Verify that the storefront connects to your sales channel:
- Ensure that the home page, product listing, and product detail pages display the correct data.
- Check that browser requests to
/service,/ext, and/graphqlsucceed. - Confirm that cart and login flows function properly.
- Make sure the browser always uses the Fastify URL, not the internal Webpack port.
Further Reading
- Continue with the shared source layout and customization workflow in Theme Development.