How to resolve deprecated node-uuid message

When installing npm packages, you might see a warning message that says node-uuid is deprecated.

The message look as follows:

npm WARN deprecated [email protected]: Use uuid module instead

The message appears because the development of the node-uuid package has stopped since 2017.

There’s a new project named uuid which is the successor of node-uuid.

The module node-uuid is still available from npm for backward compatibility purposes.

To resolve the deprecated warning message, you need to replace node-uuid with uuid as shown below:

npm uninstall --save node-uuid
npm install --save uuid

The uuid package should now be added to the dependencies list in your package.json file.

At times, the warning may show up when you install a certain package from npm.

One example is when you install an old version of the cordova package:

$ npm install [email protected]
# ...
npm WARN deprecated [email protected]: Use uuid module instead

The deprecated warning appears because cordova depends on the node-uuid package.

Only the package maintainers can update the dependency. To resolve the warning, you should look to the Github page of the project and see if there’s a newer package that depends on uuid instead of node-uuid.

At the time of this writing, all actively maintained npm packages should already switch to uuid from node-uuid.

And that’s how you resolve the node-uuid deprecated message.

Take your skills to the next level ⚡️

I'm sending out an occasional email with the latest tutorials on programming, web development, and statistics. Drop your email in the box below and I'll send new stuff straight into your inbox!

No spam. Unsubscribe anytime.