

# Tag operations
<a name="tag-operations"></a>

Tags can help you categorize and allocate costs incurred by your Quick Sight resources. For more information about tags, see [User-defined cost allocation tags](https://docs.aws.amazon.com/awsaccountbilling/latest/aboutv2/custom-tags.html). You can visualize costs of tagged resources that have consumption-based pricing in AWS cost and usage reports. For more information on cost and usage reports, see [What are AWS Cost and Usage Reports](https://docs.aws.amazon.com//cur/latest/userguide/what-is-cur.html).

You can also use tags to scope user permissions by granting a user permission to access or change only resources with certain tag values. You can use the [TagResource](tag-resource.md) API operation with a resource that already has tags. If you specify a new tag key for the resource, this tag is appended to the list of tags associated with the resource. If you specify a tag key that is already associated with the resource, the new tag value that you specify replaces the previous value for that tag. You can tag a new Quick Sight managed user or IAM user at creation with a [RegisterUser](register-user.md) API call.

You can associate as many as 50 tags with a resource. Amazon Quick Sight supports tagging for a data sets, data sources, dashboards, users, and templates.

Tagging for Quick Sight works in a similar way to tagging for other AWS services. Quick Sight doesn't currently support the tag editor for AWS Resource Groups.

Tags that are used for Admin Pro, Author Pro, or Reader Pro users can't be used as cost allocation tags.

For more information about the Tag API operations, see the following topics.

**Topics**
+ [

# ListTagsForResource
](list-tags-for-resource.md)
+ [

# TagResource
](tag-resource.md)
+ [

# UntagResource
](untag-resource.md)
+ [RegisterUser](register-user.md)

# ListTagsForResource
<a name="list-tags-for-resource"></a>

Use the `ListTagsForResource` API operation to list tags assigned to a resource. 

Following is an example AWS CLI command for this operation. To find a resource’s Amazon Resource Name (ARN), use the `List` operation for the resource. For example, `ListDashboards`.

------
#### [ AWS CLI ]

```
aws quicksight list-tags-for-resource 
    --resource-arn 444455556666
```

------

For more information about the `ListTagsForResource` API operation, see [ListTagsForResource](https://docs.aws.amazon.com/quicksight/latest/APIReference/API_ListTagsForResource.html) in the *Amazon Quick Sight API Reference*.

# TagResource
<a name="tag-resource"></a>

Use the `TagResource` API operation to assign one or more tags (key-value pairs) to the specified Amazon Quick Sight resource. 

Following is an example AWS CLI command for this operation. To find a resource's Amazon Resource Name (ARN), use the `List` operation for the resource, for example `ListDashboards`.

------
#### [ AWS CLI ]

```
aws quicksight tag-resource 
    --resource-arn 777788889999 
    --tags Key=NewDashboard,Value=True
```

------

For more information about the `TagResource` API operation, see [TagResource](https://docs.aws.amazon.com/quicksight/latest/APIReference/API_TagResource.html) in the *Amazon Quick Sight API Reference*.

# UntagResource
<a name="untag-resource"></a>

Use the `UntagResource` API operation to remove a tag from a resource. Before you do so, you can call the `ListTagsForResource` API operation to list the tags assigned to a resource.

Following is an example AWS CLI command for this operation. To find a resource’s Amazon Resource Name (ARN), use the `List` operation for the resource, for example `ListDashboards`.

------
#### [ AWS CLI ]

```
aws quicksight untag-resource 
    --resource-arn 777788889999 
    --tag-keys NewDashboard,ExampleDashboard
```

------

For more information about the `UntagResource` API operation, see [UntagResource](https://docs.aws.amazon.com/quicksight/latest/APIReference/API_UntagResource.html) in the *Amazon Quick Sight API Reference*.