Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

zaster's avatar

Error: EINVAL: invalid argument, mkdir 'C:\Users\Peter.000\'C:\Users\User\AppData\Roaming\npm''

I have installed node 12.16.2

Unfortunately, when i run

npm

i am getting an error

I think this is due to some default user account issue occurred after i updated windows 10

Previously my user account was at C:\Users\Peter

after the windows 10 update it is now at C:\Users\Peter.000

I doubt that this has a direct connection to the error mentioned in the subject

0 likes
5 replies
zaster's avatar

I was able to create another windows account and run npm from there. However, still couldn't find out a way to run npm from my default windows user account (C:\Users\Peter.000)

zaster's avatar

@siangboon that link was very helpful. Was able to sort the issue. Thank you very much :)

Please or to participate in this conversation.