Set environment variable in npm - export in command line not working

Describe the problem/error/question

I want to set an environment variable by command line using the export command, e.g. export N8N_CONFIG_FILES=path/filename. I am using n8n via npm. I am entering the export command in windows CLI (cmd.exe). But command “export” is not known. What am I doing wrong?

What is the error message (if any)?

The command export is not known

Information on your n8n setup

  • n8n version: 1.16.0
  • Database (default: SQLite):
  • n8n EXECUTIONS_PROCESS setting (default: own, main):
  • Running n8n via (Docker, npm, n8n cloud, desktop app): npm
  • Operating system: Windows 11 Pro

Hey @pghahrem,

On windows to set an environment variable you would possible want to use set instead of export. Give that a go and let us know how you get on.

Hi Jon, that works fine. Thanks for your help!

1 Like

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.