Directus Metalsmith Snipcart is a boilerplate web app template that demonstrates an API-first, decoupled CMS architecture by combining the Directus headless CMS with the Metalsmith static site generator, Vue.js, and Snipcart ecommerce.
What is Directus Metalsmith Snipcart?
Directus Metalsmith Snipcart is a lookbook web app starter that shows how to build a JAMstack site with dynamic content managed in Directus, an open source headless CMS. The repository pairs Metalsmith as the static site generator with a Vue.js component for rendering content and Snipcart for product checkout. It accepts product data defined in Directus and outputs a fully static site with ecommerce. The template runs on Netlify as shown by the live demo.
Key Features
- Directus headless CMS — Open source content management with an API-first design; content is managed in Directus and fetched into the site.
- Metalsmith static site generation — Metalsmith generates the static site from the content, producing deployable HTML.
- Vue.js component — A Vue.js component renders the dynamic content, enabling interactive lookbook displays.
- Snipcart ecommerce — Product checkout is handled by Snipcart, with products defined via the CMS.
- JAMstack demo — The repo demonstrates a decoupled architecture: content API, static generation, and client-side interactions.
- Live demo — A working demo is hosted at snipcart-directus-metalsmith.netlify.com, and the full tutorial is available on the Snipcart blog.
- Open source — The repository is open source with topics indicating headless-cms, jamstack, and static-site-generator.
Who is it for?
- Developers learning API-first CMS architectures — They can use this repo to see how Directus, Metalsmith, Vue.js, and Snipcart work together.
- JAMstack developers — Those wanting a starter for a content-managed static ecommerce site can adapt this lookbook pattern.
- Ecommerce site builders — They can use the template's Snipcart integration as a reference for adding cart and checkout to a static site.
What can you do with Directus Metalsmith Snipcart?
- Build a product lookbook — Structure product entries in Directus and display them via the Metalsmith and Vue.js pipeline.
- Create a content-managed static ecommerce site — Manage products and pages in Directus, generate a static site with Metalsmith, and handle transactions with Snipcart.
- Learn a decoupled CMS workflow — The repository serves as a working example of the API-first approach, with the source code available for study.
How does it work?
The workflow follows an API-first pattern: content is authored in Directus, which exposes it through a REST API; Metalsmith builds the static site by fetching that content; Vue.js components render the product lookbook in the browser; and Snipcart handles checkout. The tutorial linked from the repository walks through each step of setting up Directus, connecting Metalsmith, and integrating Snipcart.
FAQ
Is Directus Metalsmith Snipcart free?
The repository is open source and publicly available, so you can freely view, copy, and use the code for your own projects.
What does Directus do in this template?
Directus is the headless CMS used to manage content; it acts as the content API that Metalsmith fetches during the build.
Can I use a different static site generator?
The repo is built specifically with Metalsmith, but the API-first pattern shown can be adapted to other JAMstack tools.
Where is the live demo?
The live demo is available at snipcart-directus-metalsmith.netlify.com.





