Tags:
- Admin GraphQL API
- 2026-01
InventoryItem.variant field deprecated in favor of InventoryItem.variants connection
The field has been deprecated and will be removed in a future API version. Use the new connection instead.
To learn more, see object or query in the GraphQL Admin API reference.
Why we're making this change
The new variants connection allows for retrieving through a paginated connection, rather than a single variant object. This update prepares the API to support multiple variants sharing a single inventory item in the future.
Initially the variants connection will return a single node. However, we recommend updating your integrations to handle variants as a connection to accommodate future changes.
What you need to do
Modify your GraphQL queries by replacing variant with variants. Since variants is a connection, ensure you request edges and nodes. Although the deprecated variant field remains functional in all supported API versions, including 2026-01 , it will eventually be removed. Updating your queries now will ensure they remain compatible with future API versions.
Before (deprecated):
{
inventoryItem(id: "gid://shopify/InventoryItem/123") {
variant {
id
sku
}
}
}
After (recommended):
{
inventoryItem(id: "gid://shopify/InventoryItem/123") {
variants(first: 10) {
edges {
node {
id
sku
}
}
}
}
}