To get the npm version itself you can run npm –version.
For getting version of locally installed packages, run npm list. For globally installed packages run npm list–g.
You can get the version of a specific package by just adding the package name to argument. For example npm list grunt. This will output:
If you didn’t pass the package name into argument you will get the list of all packages with the version.