There was an error initializing DB: SQLite package has not been found installed. Try to install it: npm install sqlite3 --save

After installing the latest version of n8n and running the n8n start the command, I am getting this error

C:>n8n start
There was an error initializing DB: SQLite package has not been found installed. Try to install it: npm install sqlite3 --save

Stopping n8n…

Machine Specification:

OS: Windows Server 2016
npm: 7.3.0
Node.js v15.5.0.
Visual Studio 2019

Can Someone help me solve this?

P.S. I am using the npm approach as I only have few cron based workflows.

I am very sorry. Sadly do not run windows for many years, so have no experience here. Maybe another community member can help you to figure out what is going on.

If not, it is probably best to simply uninstall n8n and then reinstall it. The data is saved separately in your home-folder in the folder .n8n. So your workflows and credentials will not be lost and n8n will find them again automatically.

This should work on Windows:

npm install -g windows-build-tools
git clone https://github.com/n8n-io/n8n
cd n8n
lerna bootstrap --hoist
npm run build
npm run start

Hi Ivov,

I tried your approach but was getting some error when I run npm run build cmd. So, I chose to completely remove and reinstall n8n.

Thanks for the quick response!

Hi Jan,

As always thanks for the quick response! You advice of reinstalling n8n help. I was scare that i will loose all work flow. But, after you mentioned that uninstallation process wont remove workflow, I was confidently able to resolve this issue.

Thanks Again !

You are welcome. Really glad to hear that it helped.

Wish you a great weekend & Have fun!