Features and capabilities of the Retail API

Recommendations and Retail Search use the Retail API. You can use the Retail API to upload and manage product catalog information and user event logs for your ecommerce applications. You can get and customize results based on this information, and the Retail API continues to use this data to train and update models that improve your predictions and search results.

For more information about the process of implementing Retail for your application, see Implementing Retail.


Recommendations enables you to build high quality, personalized product recommendation systems without requiring a high level of expertise in machine learning, systems design, or operations. Leveraging your site's retail products and user behavior, you can use Recommendations to build recommendation models specific to your use case, such as "Frequently Bought Together" and "Recommended for You".

The Retail API uses user events and your product catalog to train your recommendation machine learning models, which provide recommendations based on this data.

When you deploy recommendation models to your application, you can then request recommendations for other products in your catalog and display to your users.

Recommendations capabilities include:

  • Custom models. Each model is trained specifically for your data, based on sequence-based machine learning models using transformers.

  • Personalized results. Leverage personalization algorithms without any machine learning expertise. Recommendations are based on user behavior and activities like views, clicks, and in-store purchases as well as online activity, so that every prediction result is personalized.

  • Real-time predictions. Each recommendation served considers previous user activity like click, view, and purchase events, so recommendations are in real time.

  • Automatic model training and tuning. Daily model retraining ensures all the models can accurately capture user behavior every day.

  • Optimization objectives. Goals like conversion rate, click-through rate, and revenue optimization help you precisely optimize for your business goal.

  • Omnichannel recommendations. With the API model, go beyond website recommendations to personalize your entire shopper journey to recommendations on mobile apps, personalized email recommendations, store kiosks, or call center applications.

Retail Search enables you to provide high quality product search results that are customizable for your retail business needs. Leverage Google's query and contextual understanding to improve product discovery across your website and mobile applications.

Retail Search capabilities include:

  • Product hierarchies: You can include collections and variants in your searchable product catalog.

  • Query expansion: Increase the relevant results returned for query terms that would normally produce fewer results, such as queries that use very specific keywords.

  • Relevance thresholding: Adjust how Retail balances returning precision (the relevance of the search results returned) and recall (returning more results for that query).

  • Pagination: Control pagination of your search results to decrease lookup time and response size.

  • Filtering: Use expression syntax to provide filtering that refines your site's search results.

  • Ordering: Set the order of search results by multiple fields in order of priority.

  • Faceting: Generate faceting to provide more relevant options to your users based on attributes you provide. Buckets need to be provided for numerical attributes in the search request to return them in the search response.

  • Dynamic faceting: Automatically generate facet keys based on search queries and automatically combine (and rerank) with facet keys provided in the search request. This feature is currently based on an allowlist. Contact Retail Search support for help enabling this feature.

  • Boosting and burying: Control search result ranking by prioritizing or deprioritizing some types of results.

  • Browsing: Get results that are sorted to maximize revenue when your users browse products using site navigation. Browse search can be combined with filtering, ordering, faceting, dynamic faceting, boosting, and burying.

  • Personalized results. Deliver personalized text search and browse search results that are personalized for each end-user, based on each user's behavior on your site, including each user's history of product views, clicks, add to cart, and purchases.

Use the Retail API

In order to build machine learning models for recommendations or search, Retail needs two sets of information:

  • Product catalog: Information about the products being recommended to customers. This includes the product title, description, in-stock availability, and pricing.

  • User events: End user behavior on your website. This includes events such as when a user views or purchases a specific item, or when your website shows the user a list of products.

With many integration options, you can ingest your data using tools you might already use, such as BigQuery, Cloud Storage, Merchant Center, Tag Manager, and Google Analytics.