Step1) Open command Prompt (type cmd in search and press Enter)
Step 2) Type command ” npm uninstall cypress”
The system will start uninstalling cypress and will show the below message.
C:\Users\Admin>npm uninstall cypress
removed 163 packages, and audited 1 package in 15s
found 0 vulnerabilities
Step 3) If you get below error then try to navigate to the directory where cypress is installed from the command line
npm ERR! code EPERM
npm ERR! syscall mkdir
npm ERR! path E:\
npm ERR! errno -4048
npm ERR! Error: EPERM: operation not permitted, mkdir ‘E:\’
npm ERR! [Error: EPERM: operation not permitted, mkdir ‘E:\’] {
npm ERR! errno: -4048,
npm ERR! code: ‘EPERM’,
npm ERR! syscall: ‘mkdir’,
npm ERR! path: ‘E:\’
npm ERR! }
npm ERR!
npm ERR! The operation was rejected by your operating system.
npm ERR! It’s possible that the file was already in use (by a text editor or antivirus),
npm ERR! or that you lack permissions to access it.”
Step 4) Navigate to the directory where cypress is installed using the cd command in the command line
Step 5) Type command “npm uninstall cypress” and press enter
After a couple of seconds, the system will uninstall cypress and will show the below message.
removed 163 packages, and audited 1 package in 6s
found 0 vulnerabilities
If you want to reinstall cypress from step 1 on windows then follow the article install cypress on windows.
To remove dependencies from the package.json file we can use the command “npm uninstall <name> –save”
This will uninstall cypress and also remove dependencies from the package.json file.