> ## Documentation Index
> Fetch the complete documentation index at: https://wb-21fd5541-feat-cli-docs-generator.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# What is a service account, and why is it useful?

A **service account** represents a non-human or machine identity, which can automate common tasks across teams and projects. Service accounts are ideal for CI/CD pipelines, automated training jobs, and other machine-to-machine workflows.

Key benefits of service accounts:

* **No license consumption**: Service accounts do not consume user seats or licenses
* **Dedicated API keys**: Secure credentials for automated workflows
* **User attribution**: Optionally attribute automated runs to human users
* **Enterprise-ready**: Built for production automation at scale
* **Delegated operations**: Service accounts operate on behalf of the user or organization that creates them

Among other things, service accounts are useful for tracking automated jobs logged to wandb, like periodic retraining, nightly builds, and so on. If you'd like, you can associate a username with one of these machine-launched runs with the [environment variables](/models/track/environment-variables/) `WANDB_USERNAME` or `WANDB_USER_EMAIL`.

For comprehensive information about service accounts, including best practices and detailed setup instructions, refer to [Use service accounts to automate workflows](/platform/hosting/iam/service-accounts/). For information about how service accounts behave in team contexts, refer to [Team Service Account Behavior](/platform/app/settings-page/teams/#team-service-account-behavior).

You can get the API key for a service account in your team at `<WANDB_HOST_URL>/<your-team-name>/service-accounts`. Alternatively you can go to the **Team settings** for your team and then refer to the **Service Accounts** tab.

To create a new service account for your team:

* Press the **+ New service account** button in the **Service Accounts** tab of your team
* Provide a name in the **Name** field
* Select **Generate API key (Built-in)** as the authentication method
* Press the **Create** button
* Click the **Copy API key** button for the newly created service account and store it in a secret manager or another safe but accessible location

<Note>
  Apart from the **Built-in** service accounts, W\&B also supports **External service accounts** using [identity federation for SDK and CLI](/platform/hosting/iam/identity_federation/#external-service-accounts). Use external service accounts if you are looking to automate W\&B tasks using service identities managed in your identity provider that can issue JSON Web Tokens (JWT).
</Note>
