← All fixes
npx tailwindcss init: could not determine executable to run (Tailwind v4)
#122Error
npm error could not determine executable to run
Why it happens, and why this works
Tailwind CSS v4 has no init command and no tailwind.config.js by default, and the CLI moved to the @tailwindcss/cli package. Old v3 tutorials still say npx tailwindcss init -p.
Fix
For v4 you don't need a config file: install @tailwindcss/vite (or @tailwindcss/postcss) and add @import "tailwindcss"; to your CSS. Customise theme in CSS with @theme. If you're following a v3 tutorial, install tailwindcss@3 postcss autoprefixer and then npx tailwindcss init -p works.
Did it work?
No reports yet0 worked0 didn't
Tried it yourself?
Related fixes
PowerShell: running scripts is disabled on this system (npm, npx, venv Activate.ps1)
#136File C:\...\npm.ps1 cannot be loaded because running scripts is disabled on this system. For more information, see about_Execution_Policies. (also Activate.ps1 for Python venv)
windowspowershellnpmpythonNo reports yet
npm error Missing script: "dev"
#83npm error Missing script: "dev" npm error To see a list of scripts, run: npm error npm run
Tailwind v4: trying to use tailwindcss directly as a PostCSS plugin
#121[postcss] It looks like you're trying to use `tailwindcss` directly as a PostCSS plugin. The PostCSS plugin has moved to a separate package, so to continue using Tailwind CSS with PostCSS you'll need to install `@tailwindcss/postcss` and update your PostCSS configuration.