Symptoms
- You run
stencil startand getnot ok -- Error: Error: You are using an outdated version of stencil-cli, please run $ npm install -g @bigcommerce/stencil-cli. - You run the suggested
npm install -g @bigcommerce/stencil-cli, it appears to succeed, and the nextstencil startprints the same message. stencil --versionmay already report a recent release, which makes the warning look wrong.- The problem can appear after a Node upgrade, after switching Node versions with nvm, or when the theme is started through
npm run startinstead of the globalstencilcommand.
Cause
The message does not always mean your CLI is old. In the Stencil CLI source, stencil start sends its own version to the storefront at /stencil-version-check and shows this exact message whenever the reply does not come back with an ok status. A truly outdated CLI is one reason. The others are environmental, so reinstalling alone often changes nothing.
The common causes, most likely first:
- A different
stencilis running than the one you upgraded. With several Node installations (nvm, Homebrew, a system Node), the global install lands in one location while your shell ornpm runscript resolves another. A copy listed in the theme'spackage.jsoncan also win over the global one. - The CLI really is older than the store requires. BigCommerce sets the minimum CLI version on its side and has raised it before. The September 2021 changelog set it to 3.5.0, and older installs began failing with this message, as reported in issue #766.
- The store or channel URL does not answer like a Stencil storefront. The check is sent to the store URL in your config, or to the channel you select. Issue #377 describes this message appearing for a wrong store URL, and one commenter traced it to a missing "my" in "mybigcommerce".
Resolution
- Check versions in the same shell you use for preview. Run
node -v,npm -vandstencil --versionfrom the theme directory. Current Stencil CLI releases declare Node 24 or later and npm 8 or later in their package metadata, per the Stencil CLI repository. If Node is older, upgrade it first. - Find which executable actually runs. On macOS or Linux use
command -v stencil; on Windows usewhere stencilorGet-Command stencilin PowerShell. Compare the path withnpm prefix -g. If they point at different Node installations, you upgraded one copy and are running another. - Pin the Node version if you use nvm. BigCommerce's troubleshooting guide suggests
ls ~/.nvm/versions/nodeto see installed versions andnvm use <version_number>to select one, and adding thatnvm useline to~/.bash_profile(or your shell's equivalent) so new terminals match. - Do a clean reinstall in that environment. A commenter on issue #949 suggests this sequence: run
npm uninstall -g @bigcommerce/stencil-cli, open a new terminal, confirmnode -vis the version you want, then runnpm install -g @bigcommerce/stencil-cli. BigCommerce's guide describes fully reinstalling Node.js as a last resort and does not recommend it, since it can disable other Node.js applications on your machine. - Remove a project-level copy. If the theme's
package.jsonlists@bigcommerce/stencil-clias a dependency or devDependency, remove it. BigCommerce's guide says the CLI is best installed globally and is not designed to function as a project dependency or devDependency. Start with the globalstencil startrather than an npm script while you test. - Check the store URL. Open
config.stencil.json(setups older than Stencil CLI 3.1 use a single.stencilfile) and confirm the store URL is correct, with no typos in the domain. If it is wrong, runstencil initagain, which rewrites the config files. - Test the channel directly. On a multi-storefront store, try
stencil start --channelId <id>for a specific Stencil channel. BigCommerce's CLI options reference describes--channelUrlas a way to "bypass custom domain protections", so if your custom domain sits behind such protection, pass a channel URL that reaches the storefront directly. When--channelUrlis set, the CLI uses it in place of any channel lookup. - Verify.
stencil startshould finish without the warning and print the local preview address. Load it in a browser, confirm pages render with your theme, and check thatstencil --versionmatches the latest release on npm.
If you get past this message and hit Could not fetch a list of the store channels, that is a token or permissions issue covered in Stencil start fails with 401 while fetching store channels.
How to prevent it
- Keep one Node manager per machine and set a default version so every terminal, editor and CI job resolves the same
stencil. - Reinstall the CLI after you change Node versions, and check the CLI's declared Node requirement before a major Node change.
- Keep the CLI out of theme
package.jsonfiles and document the expected Node and CLI versions in the theme's README. - Recheck the store URL after domain changes, storefront moves or new proxy rules.
B2B and multi-storefront notes
On stores with several channels, stencil start runs the version check against the channel you pick, not one fixed domain, so a warning on one channel does not mean every channel is affected. For channels whose platform is not BigCommerce, current CLI source uses the site's canonical URL when one exists. If your ERP connector, price lists or customer groups are tied to a particular channel, preview against that channel ID so what you see matches what buyers see.
When to get help
If versions, paths and URL all check out and the message persists, search or open an issue on the Stencil CLI repository with your node -v, npm -v, stencil --version and operating system, or contact BigCommerce support.
Related articles
- A custom Stencil web-page template does not appear
- Stencil start fails with 401 while fetching store channels
- A Stencil widget disappears on account URLs with query strings
- Logged-in shoppers cannot see prices in Cornerstone Quick Search
- A script added in Script Manager does not load
More in the BigCommerce knowledge base, including every article on Domains, themes and storefronts.