I want to publish my package to npm. the error I get is: Package name too similar to existing packages

403 Forbidden - PUT https://registry.npmjs.org/mypack.... - Package name too similar to existing packages; try renaming your package to '@user../mypackage...' and publishing with 'npm publish --access=public' instead

but when I try to install:

npm I mypackage...

I get the error not found:

npm ERR! 404 Not Found - GET https://registry.npmjs.org/mypackage... - Not found

Is there a way to check if the name is good for npm and not just guess? because I can't delete the package after I publish..

This behavior has been documented on the npm blog under New Package Moniker rules:

We’ve recently made some changes to how package naming works to better fight typosquatting, and help package authors pick names that stand out.

If you are publishing a new package—that is, a package that has not been in the registry before, we remove punctuation from its name and compare it to existing package names. If the names are identical without punctuation, we do not allow the package to be created.

Because react-native exists, no one can publish variations like:

  • reactnative
  • react_native
  • react.native