Error: EPERM: operation not permitted, open 'F:\projects\www\build\15.js'


{ Error: Failed to clean directory F:\projectname\www\build - EPERM: operation not permitted, lstat ‘F:\projectname\www\build\15.js’
at new BuildError (F:\IndiansInCA\node_modules@ionic\app-scripts\dist\util\errors.js:16:28)
at F:\IndiansInCA\node_modules@ionic\app-scripts\dist\clean.js:15:32
at new Promise ()
at Object.clean (F:\IndiansInCA\node_modules@ionic\app-scripts\dist\clean.js:7:12)
at buildProject (F:\IndiansInCA\node_modules@ionic\app-scripts\dist\build.js:99:13)
at F:\IndiansInCA\node_modules@ionic\app-scripts\dist\build.js:89:42
at step (F:\IndiansInCA\node_modules@ionic\app-scripts\dist\build.js:32:23)
at (F:\IndiansInCA\node_modules@ionic\app-scripts\dist\build.js:13:53)
at fulfilled (F:\IndiansInCA\node_modules@ionic\app-scripts\dist\build.js:4:58)
at hasBeenLogged: false, isFatal: false }

please provide me solution for this thanks.


In my situation it helped:

  1. clean cache with
npm cache clean --force
  1. install the latest version of npm globally as admin:
npm install -g npm@latest --force
  1. clean cache with
npm cache clean --force
  1. Try to install your component once again.

I hope this fix your issue. If it does not help, try to switch of antivirus program for a while and repeat.

This answers is comming from StackOverflow, all the credits is for @roman


not working for me . please give me another solution


Do you using windows?
Check this link.


yes i am using windows and this error is come suddenly, i am not changed anything in code.
i do all things npm uninstall , install but my project is not working.


solution is npm install -g cordova ionic