How to fix npm ERR! code ENOTOWNER npm ERR! User is not an owner of this package in npm

npmBEGINNERMEDIUMUpdated Dec 6, 2025· 103 views

The ENOTOWNER error occurs when you try to publish, unpublish, or modify an npm package you don't have ownership rights to. Verify your npm account, check the package's owner list, or request ownership from the current maintainer.

Quick fix

Fixes ENOTOWNER

npm owner ls <package-name>
  1. Check who owns the package
  2. Verify your logged-in account
  3. Request ownership from current owner
  4. Check scoped package permissions
npm — error
npm owner ls <package-name>
npm ERR! code ENOTOWNER
npm ERR! User is not an owner of this package

What this error means

This error occurs when you attempt an operation that requires package ownership—like publishing, unpublishing, or adding collaborators—but your npm account isn't listed as an owner of the package. npm packages have explicit ownership. Only users listed as owners can perform certain operations. Collaborators (non-owners) can publish new versions but cannot unpublish, add other owners, or change access settings. The error is a permission check at the npm registry level, not a local file permission issue. It means the registry rejected your request because your account lacks the necessary rights.

Typical symptoms

  • npm publish fails with 'not an owner' error
  • Cannot unpublish a package version
  • npm owner add fails for a package
  • Error occurs with npm deprecate command
  • Operations worked before but now fail (ownership changed)
  • Different npm account logged in than expected
  • Scoped package operations fail despite being org member

Common causes

  1. Attempting to publish to a package name you don't own
  2. Logged in with different npm account than intended
  3. Your ownership was removed by another owner
  4. Trying to unpublish as collaborator (not owner)
  5. Scoped package requires organization-level permissions
  6. npm authentication token lacks required permissions

How to fix "npm ERR! code ENOTOWNER npm ERR! User is not an owner of this package"

1Check who owns the package

List the current package owners:

bash
npm owner ls <package-name>

This shows all users with owner permissions. Your username must be in this list for owner-level operations.

2Verify your logged-in account

Confirm you're logged in as the correct user:

bash
npm whoami

If it shows a different account than expected:

bash
npm logout
npm login

Then enter the credentials for the account that owns the package.

3Request ownership from current owner

If you need ownership, ask a current owner to add you:

bash
# Current owner runs:
npm owner add <your-username> <package-name>

Only existing owners can add new owners.

4Check scoped package permissions

For scoped packages (@org/package), verify your organization role:

1. Go to npmjs.com and log in
2. Navigate to your organization settings
3. Check your role (owner, admin, member)
4. Ensure you have publish/manage permissions for the team

Organization admins may need to grant you specific package access.

5Use a different package name

If you're trying to publish a new package and the name is taken:

json
{
  "name": "@your-username/package-name"
}

Using a scoped name under your username or organization avoids conflicts with existing packages.

6Contact npm support for disputes

If you believe you should have ownership (e.g., the package was transferred incorrectly):

1. Go to npmjs.com/support
2. Submit a support request
3. Provide evidence of your claim (prior ownership, transfer agreement, etc.)

npm support can investigate and resolve ownership disputes.

Advanced notes

Owner vs Collaborator permissions:

| Action | Owner | Collaborator |
|--------|-------|--------------|
| Publish new versions | ✓ | ✓ |
| Unpublish versions | ✓ | ✗ |
| Add/remove owners | ✓ | ✗ |
| Deprecate package | ✓ | ✗ |
| Change access level | ✓ | ✗ |

For CI/CD publishing:

If your CI pipeline gets ENOTOWNER:
1. Verify the NPM_TOKEN has publish rights
2. Check the token was generated by an account with ownership
3. For organization packages, ensure the token has the correct scope
4. Automation tokens may have different permissions than regular tokens

Two-factor authentication:

If 2FA is enabled on your npm account, owner operations may require an OTP. In CI, use an automation token which bypasses 2FA for publishing.

Frequently asked questions

What does "ENOTOWNER" mean?
This error occurs when you attempt an operation that requires package ownership—like publishing, unpublishing, or adding collaborators—but your npm account isn't listed as an owner of the package. npm packages have explicit ownership. Only users listed as owners can perform certain operations.
How do I fix "ENOTOWNER"?
The ENOTOWNER error occurs when you try to publish, unpublish, or modify an npm package you don't have ownership rights to. Verify your npm account, check the package's owner list, or request ownership from the current maintainer.
What causes "ENOTOWNER"?
Attempting to publish to a package name you don't own Logged in with different npm account than intended Your ownership was removed by another owner
Is the "ENOTOWNER" error serious?
It is a medium-severity error — more of a blocker than a risk. The steps above resolve it.

Official resources & further reading