---
title: How to Create an API Key for a User
url: https://docs.vultr.com/platform/iam/organizations/manage-user-api-access/how-to-create-an-api-key-for-a-user
description: Create a named API key with an optional expiration date for an organization user in Vultr IAM to support a specific integration, script, or automated workflow.
publish_date: 2026-08-18T20:18:30.293780Z
last_updated: 2026-08-18T20:33:40.083238Z
---

A user in your organization can hold multiple named API keys, each with its own optional expiration date. Creating a dedicated API key for a specific integration or workflow lets you revoke that access independently without affecting the user's other keys.

Follow this guide to create an API key for a user using the Vultr Console or the Vultr API.

> [!NOTE]
> Use a root user account or a user with the **Manage Users** permission on the organization.

=== "Vultr Console"

    1. Log in to the [Vultr Console](https://console.vultr.com).
    1. Click the organization name in the top navigation bar.
    1. Click **Manage Organization**.
    1. Click **Users**.
    1. Click the user you want to create an API key for.
    1. Under **API Access**, click **Create API Key**.
    1. Enter a **Key Name**. This field is optional.
    1. To set an expiration date, select **Should the API key expire?** and choose an **Expiration Date**. Leave this unselected to create a key that does not expire.
    1. Click **Generate API Key**.
    1. Click **Copy to Clipboard** to copy the generated key.

        > [!NOTE]
        > The API key is only displayed once. Store it securely, as it cannot be retrieved again after this step.

    1. Select **I have successfully copied the key** and click **Finalize Key Generation**.

        The new key appears in the **API Keys** list on the user's management page.

=== "Vultr API"

    1. Send a `GET` request to the [**List Users** endpoint](https://www.vultr.com/api/#tag/users/operation/list-users) to retrieve all users and note the target user's `id`.

        ```console
        $ curl "https://api.vultr.com/v2/users" \
            -X GET \
            -H "Authorization: Bearer ${VULTR_API_KEY}"
        ```

    1. Send a `POST` request to the [**Create API Key** endpoint](#) to create a new API key for the user. Replace `{user-id}` with the id from the previous step and `KEY-NAME` with a name for the key. Set `expire` to `true` and provide `date_expire` to create a key that expires on a specific date, or set `expire` to `false` to create a key that never expires.

        ```console
        $ curl "https://api.vultr.com/v2/users/{user-id}/apikeys" \
            -X POST \
            -H "Authorization: Bearer ${VULTR_API_KEY}" \
            -H "Content-Type: application/json" \
            -d '{
                "name": "KEY-NAME",
                "expire": false
            }'
        ```

        A successful request returns an HTTP `202 Accepted` response containing the generated API key. Note the key value, as it is not retrievable again after this step.

    1. Send a `GET` request to the [**List API Keys** endpoint](#) to retrieve all API keys for the user. Replace `{user-id}` with the user id.

        ```console
        $ curl "https://api.vultr.com/v2/users/{user-id}/apikeys" \
            -X GET \
            -H "Authorization: Bearer ${VULTR_API_KEY}"
        ```

        Verify that the new key appears in the response.
