--- title: tagsRemove - GraphQL Admin description: Remove tags from an order, a draft order, a customer, a product, or an online store article. api_version: 2025-10 api_name: admin type: mutation api_type: graphql source_url: html: https://shopify.dev/docs/api/admin-graphql/latest/mutations/tagsRemove md: https://shopify.dev/docs/api/admin-graphql/latest/mutations/tagsRemove.md --- # tags​Remove mutation Remove tags from an order, a draft order, a customer, a product, or an online store article. ## Arguments * id [ID!](https://shopify.dev/docs/api/admin-graphql/latest/scalars/ID) required The ID of the resource to remove tags from. * tags [\[String!\]!](https://shopify.dev/docs/api/admin-graphql/latest/scalars/String) required A list of tags to remove from the resource in the form of an array of strings. Example value: `["tag1", "tag2", "tag3"]`. *** ## Tags​Remove​Payload returns * node [Node](https://shopify.dev/docs/api/admin-graphql/latest/interfaces/Node) The object that was updated. * user​Errors [\[User​Error!\]!](https://shopify.dev/docs/api/admin-graphql/latest/objects/UserError) non-null The list of errors that occurred from executing the mutation. *** ## Examples * ### Remove tags from a customer #### Query ```graphql mutation removeTags($id: ID!, $tags: [String!]!) { tagsRemove(id: $id, tags: $tags) { node { id } userErrors { message } } } ``` #### Variables ```json { "id": "gid://shopify/Customer/544365967", "tags": [ "Bob" ] } ``` #### cURL ```bash curl -X POST \ https://your-development-store.myshopify.com/admin/api/2025-10/graphql.json \ -H 'Content-Type: application/json' \ -H 'X-Shopify-Access-Token: {access_token}' \ -d '{ "query": "mutation removeTags($id: ID!, $tags: [String!]!) { tagsRemove(id: $id, tags: $tags) { node { id } userErrors { message } } }", "variables": { "id": "gid://shopify/Customer/544365967", "tags": [ "Bob" ] } }' ``` #### React Router ```javascript import { authenticate } from "../shopify.server"; export const loader = async ({request}) => { const { admin } = await authenticate.admin(request); const response = await admin.graphql( `#graphql mutation removeTags($id: ID!, $tags: [String!]!) { tagsRemove(id: $id, tags: $tags) { node { id } userErrors { message } } }`, { variables: { "id": "gid://shopify/Customer/544365967", "tags": [ "Bob" ] }, }, ); const json = await response.json(); return json.data; } ``` #### Ruby ```ruby session = ShopifyAPI::Auth::Session.new( shop: "your-development-store.myshopify.com", access_token: access_token ) client = ShopifyAPI::Clients::Graphql::Admin.new( session: session ) query = <<~QUERY mutation removeTags($id: ID!, $tags: [String!]!) { tagsRemove(id: $id, tags: $tags) { node { id } userErrors { message } } } QUERY variables = { "id": "gid://shopify/Customer/544365967", "tags": [ "Bob" ] } response = client.query(query: query, variables: variables) ``` #### Node.js ```javascript const client = new shopify.clients.Graphql({session}); const data = await client.query({ data: { "query": `mutation removeTags($id: ID!, $tags: [String!]!) { tagsRemove(id: $id, tags: $tags) { node { id } userErrors { message } } }`, "variables": { "id": "gid://shopify/Customer/544365967", "tags": [ "Bob" ] }, }, }); ``` #### Response ```json { "tagsRemove": { "node": { "id": "gid://shopify/Customer/544365967" }, "userErrors": [] } } ``` * ### tagsRemove reference [Open in GraphiQL](http://localhost:3457/graphiql?query=mutation%20removeTags\(%24id%3A%20ID!%2C%20%24tags%3A%20%5BString!%5D!\)%20%7B%0A%20%20tagsRemove\(id%3A%20%24id%2C%20tags%3A%20%24tags\)%20%7B%0A%20%20%20%20node%20%7B%0A%20%20%20%20%20%20id%0A%20%20%20%20%7D%0A%20%20%20%20userErrors%20%7B%0A%20%20%20%20%20%20message%0A%20%20%20%20%7D%0A%20%20%7D%0A%7D\&variables=%7B%0A%20%20%22id%22%3A%20%22gid%3A%2F%2Fshopify%2FCustomer%2F544365967%22%2C%0A%20%20%22tags%22%3A%20%5B%0A%20%20%20%20%22Bob%22%0A%20%20%5D%0A%7D) ```javascript import { authenticate } from "../shopify.server"; export const loader = async ({request}) => { const { admin } = await authenticate.admin(request); const response = await admin.graphql( `#graphql mutation removeTags($id: ID!, $tags: [String!]!) { tagsRemove(id: $id, tags: $tags) { node { id } userErrors { message } } }`, { variables: { "id": "gid://shopify/Customer/544365967", "tags": [ "Bob" ] }, }, ); const json = await response.json(); return json.data; } ``` ##### GQL ``` mutation removeTags($id: ID!, $tags: [String!]!) { tagsRemove(id: $id, tags: $tags) { node { id } userErrors { message } } } ``` ##### cURL ``` curl -X POST \ https://your-development-store.myshopify.com/admin/api/2025-10/graphql.json \ -H 'Content-Type: application/json' \ -H 'X-Shopify-Access-Token: {access_token}' \ -d '{ "query": "mutation removeTags($id: ID!, $tags: [String!]!) { tagsRemove(id: $id, tags: $tags) { node { id } userErrors { message } } }", "variables": { "id": "gid://shopify/Customer/544365967", "tags": [ "Bob" ] } }' ``` ##### React Router ``` import { authenticate } from "../shopify.server"; export const loader = async ({request}) => { const { admin } = await authenticate.admin(request); const response = await admin.graphql( `#graphql mutation removeTags($id: ID!, $tags: [String!]!) { tagsRemove(id: $id, tags: $tags) { node { id } userErrors { message } } }`, { variables: { "id": "gid://shopify/Customer/544365967", "tags": [ "Bob" ] }, }, ); const json = await response.json(); return json.data; } ``` ##### Node.js ``` const client = new shopify.clients.Graphql({session}); const data = await client.query({ data: { "query": `mutation removeTags($id: ID!, $tags: [String!]!) { tagsRemove(id: $id, tags: $tags) { node { id } userErrors { message } } }`, "variables": { "id": "gid://shopify/Customer/544365967", "tags": [ "Bob" ] }, }, }); ``` ##### Ruby ``` session = ShopifyAPI::Auth::Session.new( shop: "your-development-store.myshopify.com", access_token: access_token ) client = ShopifyAPI::Clients::Graphql::Admin.new( session: session ) query = <<~QUERY mutation removeTags($id: ID!, $tags: [String!]!) { tagsRemove(id: $id, tags: $tags) { node { id } userErrors { message } } } QUERY variables = { "id": "gid://shopify/Customer/544365967", "tags": [ "Bob" ] } response = client.query(query: query, variables: variables) ``` ## Input variables JSON ```json { "id": "gid://shopify/Customer/544365967", "tags": [ "Bob" ] } ``` ## Response JSON ```json { "tagsRemove": { "node": { "id": "gid://shopify/Customer/544365967" }, "userErrors": [] } } ```