Configuring .npmrc
Authenticate npm, pnpm, or yarn with the Bit registry to install and publish packages.
Log in (recommended)
The easiest way is a browser-based login, which stores your token and configures .npmrc for you — no manual edits:
npm login --registry=https://node-registry.bit.cloud
# or
bit loginnpm login and bit login produce the same token, and both work for installing and publishing.
Use a token (CI & automation)
For CI or any environment where you can not log in interactively, add an access token to .npmrc:
@my-org:registry=https://node-registry.bit.cloud
//node-registry.bit.cloud/:_authToken=BIT_CLOUD_AUTH_TOKEN
always-auth=trueReplace BIT_CLOUD_AUTH_TOKEN with an access token you generate on Bit Cloud, and @my-org with your organization or username.
Scoped registry
Bit maps each organization or username to a scoped registry. Set it per project (a .npmrc in your project root) or globally:
npm config set @my-org:registry https://node-registry.bit.cloudPrivate packages also require the _authToken and always-auth=true lines shown above.