--- title: QueryRoot - Storefront API description: >- The schema’s entry-point for queries. This acts as the public, top-level API from which all queries must start. api_version: 2026-01 api_name: storefront type: object api_type: graphql source_url: html: 'https://shopify.dev/docs/api/storefront/latest/objects/QueryRoot' md: 'https://shopify.dev/docs/api/storefront/latest/objects/QueryRoot.md' --- # Query​Root object The schema’s entry-point for queries. This acts as the public, top-level API from which all queries must start. ## Fields * article [Article](https://shopify.dev/docs/api/storefront/latest/objects/Article) Returns an [`Article`](https://shopify.dev/docs/api/storefront/2026-01/objects/Article) by its ID. Each article belongs to a [`Blog`](https://shopify.dev/docs/api/storefront/2026-01/objects/Blog) and includes content in both plain text and HTML formats, [`ArticleAuthor`](https://shopify.dev/docs/api/storefront/2026-01/objects/ArticleAuthor) information, [`Comment`](https://shopify.dev/docs/api/storefront/2026-01/objects/Comment) objects, tags, and [`SEO`](https://shopify.dev/docs/api/storefront/2026-01/objects/SEO) data. * id [ID!](https://shopify.dev/docs/api/storefront/latest/scalars/ID) required ### Arguments The ID of the `Article`. *** * articles [Article​Connection!](https://shopify.dev/docs/api/storefront/latest/connections/ArticleConnection) non-null Returns a paginated list of [`Article`](https://shopify.dev/docs/api/storefront/2026-01/objects/Article) objects from the shop's [`Blog`](https://shopify.dev/docs/api/storefront/2026-01/objects/Blog) objects. Each article is a blog post containing content, author information, tags, and optional images. Use the `query` argument to filter results by author, blog title, tags, or date fields. Sort results using the `sortKey` argument and reverse them with the `reverse` argument. * first [Int](https://shopify.dev/docs/api/storefront/latest/scalars/Int) ### Arguments Returns up to the first `n` elements from the list. * after [String](https://shopify.dev/docs/api/storefront/latest/scalars/String) Returns the elements that come after the specified cursor. * last [Int](https://shopify.dev/docs/api/storefront/latest/scalars/Int) Returns up to the last `n` elements from the list. * before [String](https://shopify.dev/docs/api/storefront/latest/scalars/String) Returns the elements that come before the specified cursor. * reverse [Boolean](https://shopify.dev/docs/api/storefront/latest/scalars/Boolean) Default:false Reverse the order of the underlying list. * sort​Key [Article​Sort​Keys](https://shopify.dev/docs/api/storefront/latest/enums/ArticleSortKeys) Default:ID Sort the underlying list by the given key. * query [String](https://shopify.dev/docs/api/storefront/latest/scalars/String) Apply one or multiple filters to the query. Refer to the detailed [search syntax](https://shopify.dev/api/usage/search-syntax) for more information about using filters. * author * blog\_title * created\_at * tag * tag\_not * updated\_at *** * blog [Blog](https://shopify.dev/docs/api/storefront/latest/objects/Blog) Retrieves a [`Blog`](https://shopify.dev/docs/api/storefront/2026-01/objects/Blog) by its handle or ID. A blog organizes [`Article`](https://shopify.dev/docs/api/storefront/2026-01/objects/Article) objects for the online store and includes author information, [`SEO`](https://shopify.dev/docs/api/storefront/2026-01/objects/SEO) settings, and custom [`Metafield`](https://shopify.dev/docs/api/storefront/2026-01/objects/Metafield) objects. * handle [String](https://shopify.dev/docs/api/storefront/latest/scalars/String) ### Arguments The handle of the `Blog`. * id [ID](https://shopify.dev/docs/api/storefront/latest/scalars/ID) The ID of the `Blog`. *** * blogs [Blog​Connection!](https://shopify.dev/docs/api/storefront/latest/connections/BlogConnection) non-null Returns a paginated list of the shop's [`Blog`](https://shopify.dev/docs/api/storefront/2026-01/objects/Blog) objects. Each blog serves as a container for [`Article`](https://shopify.dev/docs/api/storefront/2026-01/objects/Article) objects. * first [Int](https://shopify.dev/docs/api/storefront/latest/scalars/Int) ### Arguments Returns up to the first `n` elements from the list. * after [String](https://shopify.dev/docs/api/storefront/latest/scalars/String) Returns the elements that come after the specified cursor. * last [Int](https://shopify.dev/docs/api/storefront/latest/scalars/Int) Returns up to the last `n` elements from the list. * before [String](https://shopify.dev/docs/api/storefront/latest/scalars/String) Returns the elements that come before the specified cursor. * reverse [Boolean](https://shopify.dev/docs/api/storefront/latest/scalars/Boolean) Default:false Reverse the order of the underlying list. * sort​Key [Blog​Sort​Keys](https://shopify.dev/docs/api/storefront/latest/enums/BlogSortKeys) Default:ID Sort the underlying list by the given key. * query [String](https://shopify.dev/docs/api/storefront/latest/scalars/String) Apply one or multiple filters to the query. Refer to the detailed [search syntax](https://shopify.dev/api/usage/search-syntax) for more information about using filters. * created\_at * handle * title * updated\_at *** * cart [Cart](https://shopify.dev/docs/api/storefront/latest/objects/Cart) Returns a [`Cart`](https://shopify.dev/docs/api/storefront/2026-01/objects/Cart) by its ID. The cart contains the merchandise lines a buyer intends to purchase, along with estimated costs, applied discounts, gift cards, and delivery options. Use the [`checkoutUrl`](https://shopify.dev/docs/api/storefront/latest/queries/cart#returns-Cart.fields.checkoutUrl) field to redirect buyers to Shopify's web checkout when they're ready to complete their purchase. For more information, refer to [Manage a cart with the Storefront API](https://shopify.dev/docs/storefronts/headless/building-with-the-storefront-api/cart/manage). * id [ID!](https://shopify.dev/docs/api/storefront/latest/scalars/ID) required ### Arguments The ID of the cart. *** * collection [Collection](https://shopify.dev/docs/api/storefront/latest/objects/Collection) Retrieves a single [`Collection`](https://shopify.dev/docs/api/storefront/2026-01/objects/Collection) by its ID or handle. Use the [`products`](https://shopify.dev/docs/api/storefront/2026-01/objects/Collection#field-Collection.fields.products) field to access items in the collection. * id [ID](https://shopify.dev/docs/api/storefront/latest/scalars/ID) ### Arguments The ID of the `Collection`. * handle [String](https://shopify.dev/docs/api/storefront/latest/scalars/String) The handle of the `Collection`. *** * collections [Collection​Connection!](https://shopify.dev/docs/api/storefront/latest/connections/CollectionConnection) non-null Returns a paginated list of the shop's [collections](https://shopify.dev/docs/api/storefront/2026-01/objects/Collection). Each `Collection` object includes a nested connection to its [products](https://shopify.dev/docs/api/storefront/2026-01/objects/Collection#field-Collection.fields.products). * first [Int](https://shopify.dev/docs/api/storefront/latest/scalars/Int) ### Arguments Returns up to the first `n` elements from the list. * after [String](https://shopify.dev/docs/api/storefront/latest/scalars/String) Returns the elements that come after the specified cursor. * last [Int](https://shopify.dev/docs/api/storefront/latest/scalars/Int) Returns up to the last `n` elements from the list. * before [String](https://shopify.dev/docs/api/storefront/latest/scalars/String) Returns the elements that come before the specified cursor. * reverse [Boolean](https://shopify.dev/docs/api/storefront/latest/scalars/Boolean) Default:false Reverse the order of the underlying list. * sort​Key [Collection​Sort​Keys](https://shopify.dev/docs/api/storefront/latest/enums/CollectionSortKeys) Default:ID Sort the underlying list by the given key. * query [String](https://shopify.dev/docs/api/storefront/latest/scalars/String) Apply one or multiple filters to the query. Refer to the detailed [search syntax](https://shopify.dev/api/usage/search-syntax) for more information about using filters. * collection\_type * title * updated\_at *** * customer [Customer](https://shopify.dev/docs/api/storefront/latest/objects/Customer) Token access required Retrieves the [`Customer`](https://shopify.dev/docs/api/storefront/2026-01/objects/Customer) associated with the provided access token. Use the [`customerAccessTokenCreate`](https://shopify.dev/docs/api/storefront/2026-01/mutations/customerAccessTokenCreate) mutation to obtain an access token using legacy customer account authentication (email and password). The returned customer includes data such as contact information, [addresses](https://shopify.dev/docs/api/storefront/2026-01/objects/MailingAddress), [orders](https://shopify.dev/docs/api/storefront/2026-01/objects/Order), and [custom data](https://shopify.dev/docs/apps/build/custom-data) associated with the customer. * customer​Access​Token [String!](https://shopify.dev/docs/api/storefront/latest/scalars/String) required ### Arguments The customer access token. *** * localization [Localization!](https://shopify.dev/docs/api/storefront/latest/objects/Localization) non-null Returns the shop's localization settings. Use this query to build [country and language selectors](https://shopify.dev/docs/storefronts/headless/building-with-the-storefront-api/markets) for your storefront. The [`country`](https://shopify.dev/docs/api/storefront/latest/queries/localization#returns-Localization.fields.country) and [`language`](https://shopify.dev/docs/api/storefront/latest/queries/localization#returns-Localization.fields.language) fields reflect the active localized experience. To change the context, use the [`@inContext`](https://shopify.dev/docs/api/storefront#directives) directive with your desired country or language code. * locations [Location​Connection!](https://shopify.dev/docs/api/storefront/latest/connections/LocationConnection) non-null Returns shop locations that support in-store pickup. Use the `near` argument with [`GeoCoordinateInput`](https://shopify.dev/docs/api/storefront/2026-01/input-objects/GeoCoordinateInput) to sort results by proximity to the customer's location. When sorting by distance, set `sortKey` to [`DISTANCE`](https://shopify.dev/docs/api/storefront/2026-01/queries/locations#arguments-sortKey.enums.DISTANCE) and provide coordinates using the [`near`](https://shopify.dev/docs/api/storefront/2026-01/queries/locations#arguments-near) argument. Learn more about [supporting local pickup on storefronts](https://shopify.dev/docs/storefronts/headless/building-with-the-storefront-api/products-collections/local-pickup). * first [Int](https://shopify.dev/docs/api/storefront/latest/scalars/Int) ### Arguments Returns up to the first `n` elements from the list. * after [String](https://shopify.dev/docs/api/storefront/latest/scalars/String) Returns the elements that come after the specified cursor. * last [Int](https://shopify.dev/docs/api/storefront/latest/scalars/Int) Returns up to the last `n` elements from the list. * before [String](https://shopify.dev/docs/api/storefront/latest/scalars/String) Returns the elements that come before the specified cursor. * reverse [Boolean](https://shopify.dev/docs/api/storefront/latest/scalars/Boolean) Default:false Reverse the order of the underlying list. * sort​Key [Location​Sort​Keys](https://shopify.dev/docs/api/storefront/latest/enums/LocationSortKeys) Default:ID Sort the underlying list by the given key. * near [Geo​Coordinate​Input](https://shopify.dev/docs/api/storefront/latest/input-objects/GeoCoordinateInput) Used to sort results based on proximity to the provided location. *** * menu [Menu](https://shopify.dev/docs/api/storefront/latest/objects/Menu) Token access required Retrieves a [`Menu`](https://shopify.dev/docs/api/storefront/2026-01/objects/Menu) by its handle. Menus are [hierarchical navigation structures](https://help.shopify.com/manual/online-store/menus-and-links) that merchants configure for their storefront, such as header and footer navigation. Each menu contains [`MenuItem`](https://shopify.dev/docs/api/storefront/2026-01/objects/MenuItem) objects that can nest up to three levels deep, with each item linking to [collections](https://shopify.dev/docs/api/storefront/2026-01/objects/Collection), [products](https://shopify.dev/docs/api/storefront/2026-01/objects/Product), [pages](https://shopify.dev/docs/api/storefront/2026-01/objects/Page), [blogs](https://shopify.dev/docs/api/storefront/2026-01/objects/Blog), or external URLs. * handle [String!](https://shopify.dev/docs/api/storefront/latest/scalars/String) required ### Arguments The navigation menu's handle. *** * metaobject [Metaobject](https://shopify.dev/docs/api/storefront/latest/objects/Metaobject) Token access required Retrieves a single [`Metaobject`](https://shopify.dev/docs/api/storefront/2026-01/objects/Metaobject) by either its [`global ID`](https://shopify.dev/docs/api/storefront/2026-01/queries/metaobject#arguments-id) or its [`handle`](https://shopify.dev/docs/api/storefront/2026-01/queries/metaobject#arguments-handle). *** **Note:** When using the handle, you must also provide the metaobject type because handles are only unique within a type. *** * id [ID](https://shopify.dev/docs/api/storefront/latest/scalars/ID) ### Arguments The ID of the metaobject. * handle [Metaobject​Handle​Input](https://shopify.dev/docs/api/storefront/latest/input-objects/MetaobjectHandleInput) The handle and type of the metaobject. *** * metaobjects [Metaobject​Connection!](https://shopify.dev/docs/api/storefront/latest/connections/MetaobjectConnection) non-null Token access required Returns a paginated list of [`Metaobject`](https://shopify.dev/docs/api/storefront/2026-01/objects/Metaobject) entries for a specific type. Metaobjects are [custom data structures](https://shopify.dev/docs/apps/build/metaobjects) that extend Shopify's data model with merchant-defined or app-defined content like size charts, product highlights, or custom sections. The required `type` argument specifies which metaobject type to retrieve. You can sort results by `id` or `updated_at` using the `sortKey` argument. * type [String!](https://shopify.dev/docs/api/storefront/latest/scalars/String) required ### Arguments The type of metaobject to retrieve. * sort​Key [String](https://shopify.dev/docs/api/storefront/latest/scalars/String) The key of a field to sort with. Supports "id" and "updated\_at". * first [Int](https://shopify.dev/docs/api/storefront/latest/scalars/Int) Returns up to the first `n` elements from the list. * after [String](https://shopify.dev/docs/api/storefront/latest/scalars/String) Returns the elements that come after the specified cursor. * last [Int](https://shopify.dev/docs/api/storefront/latest/scalars/Int) Returns up to the last `n` elements from the list. * before [String](https://shopify.dev/docs/api/storefront/latest/scalars/String) Returns the elements that come before the specified cursor. * reverse [Boolean](https://shopify.dev/docs/api/storefront/latest/scalars/Boolean) Default:false Reverse the order of the underlying list. *** * node [Node](https://shopify.dev/docs/api/storefront/latest/interfaces/Node) Returns a specific node by ID. * id [ID!](https://shopify.dev/docs/api/storefront/latest/scalars/ID) required ### Arguments The ID of the Node to return. *** * nodes [\[Node\]!](https://shopify.dev/docs/api/storefront/latest/interfaces/Node) non-null Returns the list of nodes with the given IDs. * ids [\[ID!\]!](https://shopify.dev/docs/api/storefront/latest/scalars/ID) required ### Arguments The IDs of the Nodes to return. The input must not contain more than `250` values. *** * page [Page](https://shopify.dev/docs/api/storefront/latest/objects/Page) Retrieves a [`Page`](https://shopify.dev/docs/api/storefront/2026-01/objects/Page) by its [`handle`](https://shopify.dev/docs/api/storefront/2026-01/queries/page#arguments-handle) or [`id`](https://shopify.dev/docs/api/storefront/2026-01/queries/page#arguments-id). Pages are static content pages that merchants display outside their product catalog, such as "About Us," "Contact," or policy pages. The returned page includes information such as the [HTML body content](https://shopify.dev/docs/api/storefront/2026-01/queries/page#returns-Page.fields.body), [`SEO`](https://shopify.dev/docs/api/storefront/2026-01/objects/SEO) information, and any associated [`Metafield`](https://shopify.dev/docs/api/storefront/2026-01/objects/Metafield) objects. * handle [String](https://shopify.dev/docs/api/storefront/latest/scalars/String) ### Arguments The handle of the `Page`. * id [ID](https://shopify.dev/docs/api/storefront/latest/scalars/ID) The ID of the `Page`. *** * pages [Page​Connection!](https://shopify.dev/docs/api/storefront/latest/connections/PageConnection) non-null Returns a paginated list of the shop's content [pages](https://shopify.dev/docs/api/storefront/2026-01/objects/Page). Pages are custom HTML content like "About Us", "Contact", or policy information that merchants display outside their product catalog. * first [Int](https://shopify.dev/docs/api/storefront/latest/scalars/Int) ### Arguments Returns up to the first `n` elements from the list. * after [String](https://shopify.dev/docs/api/storefront/latest/scalars/String) Returns the elements that come after the specified cursor. * last [Int](https://shopify.dev/docs/api/storefront/latest/scalars/Int) Returns up to the last `n` elements from the list. * before [String](https://shopify.dev/docs/api/storefront/latest/scalars/String) Returns the elements that come before the specified cursor. * reverse [Boolean](https://shopify.dev/docs/api/storefront/latest/scalars/Boolean) Default:false Reverse the order of the underlying list. * sort​Key [Page​Sort​Keys](https://shopify.dev/docs/api/storefront/latest/enums/PageSortKeys) Default:ID Sort the underlying list by the given key. * query [String](https://shopify.dev/docs/api/storefront/latest/scalars/String) Apply one or multiple filters to the query. Refer to the detailed [search syntax](https://shopify.dev/api/usage/search-syntax) for more information about using filters. * created\_at * handle * title * updated\_at *** * payment​Settings [Payment​Settings!](https://shopify.dev/docs/api/storefront/latest/objects/PaymentSettings) non-null Settings related to payments. * predictive​Search [Predictive​Search​Result](https://shopify.dev/docs/api/storefront/latest/objects/PredictiveSearchResult) Returns suggested results as customers type in a search field, enabling type-ahead search experiences. The query matches [products](https://shopify.dev/docs/api/storefront/2026-01/objects/Product), [collections](https://shopify.dev/docs/api/storefront/2026-01/objects/Collection), [pages](https://shopify.dev/docs/api/storefront/2026-01/objects/Page), and [articles](https://shopify.dev/docs/api/storefront/2026-01/objects/Article) based on partial search terms, and also provides [search query suggestions](https://shopify.dev/docs/api/storefront/2026-01/objects/SearchQuerySuggestion) to help customers refine their search. You can filter results by resource type and limit the quantity. The [`limitScope`](https://shopify.dev/docs/api/storefront/2026-01/queries/predictiveSearch#arguments-limitScope) argument controls whether limits apply across all result types or per type. Use [`unavailableProducts`](https://shopify.dev/docs/api/storefront/2026-01/queries/predictiveSearch#arguments-unavailableProducts) to control how out-of-stock products appear in results. * limit [Int](https://shopify.dev/docs/api/storefront/latest/scalars/Int) ### Arguments Limits the number of results based on `limit_scope`. The value can range from 1 to 10, and the default is 10. * limit​Scope [Predictive​Search​Limit​Scope](https://shopify.dev/docs/api/storefront/latest/enums/PredictiveSearchLimitScope) Decides the distribution of results. * query [String!](https://shopify.dev/docs/api/storefront/latest/scalars/String) required The search query. * searchable​Fields [\[Searchable​Field!\]](https://shopify.dev/docs/api/storefront/latest/enums/SearchableField) Specifies the list of resource fields to use for search. The default fields searched on are TITLE, PRODUCT\_TYPE, VARIANT\_TITLE, and VENDOR. For the best search experience, you should search on the default field set. The input must not contain more than `250` values. * types [\[Predictive​Search​Type!\]](https://shopify.dev/docs/api/storefront/latest/enums/PredictiveSearchType) The types of resources to search for. The input must not contain more than `250` values. * unavailable​Products [Search​Unavailable​Products​Type](https://shopify.dev/docs/api/storefront/latest/enums/SearchUnavailableProductsType) Specifies how unavailable products are displayed in the search results. *** * product [Product](https://shopify.dev/docs/api/storefront/latest/objects/Product) Retrieves a single [`Product`](https://shopify.dev/docs/api/storefront/2026-01/objects/Product) by its ID or handle. Use this query to build product detail pages, access variant and pricing information, or fetch product media and [metafields](https://shopify.dev/docs/api/storefront/2026-01/objects/Metafield). See some [examples of querying products](https://shopify.dev/docs/storefronts/headless/building-with-the-storefront-api/products-collections/getting-started). * id [ID](https://shopify.dev/docs/api/storefront/latest/scalars/ID) ### Arguments The ID of the `Product`. * handle [String](https://shopify.dev/docs/api/storefront/latest/scalars/String) The handle of the `Product`. *** * product​Recommendations [\[Product!\]](https://shopify.dev/docs/api/storefront/latest/objects/Product) Returns recommended products for a given product, identified by either ID or handle. Use the [`intent`](https://shopify.dev/docs/api/storefront/2026-01/enums/ProductRecommendationIntent) argument to control the recommendation strategy. Shopify [auto-generates related recommendations](https://shopify.dev/docs/storefronts/themes/product-merchandising/recommendations) based on sales data, product descriptions, and collection relationships. Complementary recommendations require [manual configuration](https://help.shopify.com/manual/online-store/storefront-search/search-and-discovery-recommendations) through the Shopify Search & Discovery app. Returns up to ten [`Product`](https://shopify.dev/docs/api/storefront/2026-01/objects/Product) objects. * product​Id [ID](https://shopify.dev/docs/api/storefront/latest/scalars/ID) ### Arguments The id of the product. * product​Handle [String](https://shopify.dev/docs/api/storefront/latest/scalars/String) The handle of the product. * intent [Product​Recommendation​Intent](https://shopify.dev/docs/api/storefront/latest/enums/ProductRecommendationIntent) Default:RELATED The recommendation intent that is used to generate product recommendations. You can use intent to generate product recommendations on various pages across the channels, according to different strategies. *** * products [Product​Connection!](https://shopify.dev/docs/api/storefront/latest/connections/ProductConnection) non-null Returns a paginated list of the shop's [products](https://shopify.dev/docs/api/storefront/2026-01/objects/Product). For full-text storefront search, use the [`search`](https://shopify.dev/docs/api/storefront/2026-01/queries/search) query instead. * first [Int](https://shopify.dev/docs/api/storefront/latest/scalars/Int) ### Arguments Returns up to the first `n` elements from the list. * after [String](https://shopify.dev/docs/api/storefront/latest/scalars/String) Returns the elements that come after the specified cursor. * last [Int](https://shopify.dev/docs/api/storefront/latest/scalars/Int) Returns up to the last `n` elements from the list. * before [String](https://shopify.dev/docs/api/storefront/latest/scalars/String) Returns the elements that come before the specified cursor. * reverse [Boolean](https://shopify.dev/docs/api/storefront/latest/scalars/Boolean) Default:false Reverse the order of the underlying list. * sort​Key [Product​Sort​Keys](https://shopify.dev/docs/api/storefront/latest/enums/ProductSortKeys) Default:ID Sort the underlying list by the given key. * query [String](https://shopify.dev/docs/api/storefront/latest/scalars/String) You can apply one or multiple filters to a query. Learn more about [Shopify API search syntax](https://shopify.dev/api/usage/search-syntax). * available\_for\_sale Filter by products that have at least one product variant available for sale. * * created\_at * product\_type * tag * tag\_not * title * updated\_at * variants.price - Filter by the date and time when the product was created. - Example: * `created_at:>'2020-10-21T23:39:20Z'` * `created_at:'2020-10-21T23:39:20Z'` * `updated_at: