The Complete Guide to Magento 2 Related Products, Up-sells, and Cross-sells, and how to import them

The triplet ‘related products, up-sells, and cross-sells’ can be called ‘a promo engine for an e-store’. The products are distinguished based on the display location and they may serve specific marketing goals but the core idea of being a purchase stimulus is similar for all of them. In this guide, we will cover how to enrich your store content by importing related products, cross-sells, and up-sells.

From this blog post you will learn how to use, import, and export Magento 2 related products, up-sells, and cross-sells. The post is another one in the series of educational posts dedicated to Magento 2 import and export processes. Other guides can be found in the Magento 2 Import/Export Guide list.

Read Magento 2 import and export Guide List

To sell effectively one must learn to predict and analyze. What are people looking for at my store? How can I make their search fruitful? At what point do the results become satisfying? Will it be enough to improve customer lives? The answers to the questions lie within everyone’s reach — run through some behavior statistics and create the most relevant offers for your audience. The related product, up-sell, and cross-sell functionalities are the very tools that will help you understand the customers’ needs.

What are Magento 2 related products

Related products are selection of products connected to another one. Whether it is based on the same category affiliation or on how often the items are bought together you can set the relations between multiple products.

Customers see these promo objects every time they visit one of the listed product pages. Related product block place is determined by a store layout: it can be displayed at the bottom of the page, or in the sidebar, etc.

Related products are configured in the backend in a few steps. Just specify the list of items that may attract your customers in combo (e.g. a yoga mat + yoga video courses) and, thus, you will push them to buy an extra item or two.

What are Magento 2 up-sell products

To up the stakes and involve customers deeper into the diversity of your store content use up-sell product promotion. Technically similar to related products these products are meant for item interchange with a slight difference in options.

Up-sells are displayed on a product page to advertise goods more profitable for your business than the one is currently being viewed. You offer products that are pretty much the same, but the quality is better, the functionality is improved, the brand is more famous. And that implies the higher price.

It’s sort of a trick to play on the human tendency to get the best out of any situation. You encourage customers to try new opportunities, and they pay you willingly more for pleasure. The case where both sides win.

What are Magento 2 cross-sell products

No one wants to miss chances. Not to promote in a shopping cart is a waste.
Cross-sells are the last chance to trigger the impulse purchase (the very case when you see a tempting thing — you buy it), that’s why the products for the task must be selected carefully.
The same as with related products and up-sells, cross-sells are added manually from the backend and are shown in a shopping cart. Literally a step away from checkout it’s still possible to persuade customers to make an additional purchase. Keep in mind to plan what kind of promotions you want to run with up-sells, e.g. price-based ones, bestsellers display, or offering products that amplify the functionality of a product in a cart.

Assigning related products, up-sells, and cross-sells

It is not an accident that related products, up-sells, and cross-sells are often put together in guides. The thing is they share both the primary promo goal and the assigning process.

To retrace the path we start with following Catalog > Products.

  • Select a product you need and click ‘Edit’
  • Scroll down the product setting page to the ‘Related Products, Up-Sells, and Cross-Sells’ section

Choose ‘Add Products’ for any of the options or for all of them.

  • Decide on what to add in a popover with the product list.

NOTE: You can switch between the show/hide options for cross-sells depending on a store view. Go to Store > Configuration > Sales > Checkout > Shopping Cart and change the status of ‘Show Cross-sell Items in the Shopping Cart’.

Importing & Exporting related products, up-sells, and cross-sells

In this guide, we are going to show how to import & export related products, up-sells, and cross-sells in a CSV file as it is the most commonly used format, but keep in mind that Magento 2 Improved Import & Export allows using various file types to define the import/export source.

We strongly advise using Google Sheets for editing CSV tables, as this is a the most convenient and simple way of editing CSV tables. See the detailed guide to how to use Google Sheets to edit CSV files, and how to import directly from the Google Sheets. Read Google Sheet Master Import Table guide.

As you can see from the screenshot above, the related items are imported along with the Magento 2 products using the dedicated columns. Below we describe how to fill in these columns and how to compose the import table.

Attributes in a CSV table

To perform the import create a CSV file with the product data. Specifying related products, up-sells, and cross-sells will require three corresponded columns in the table.

  • related_skus – for related products
  • crosssell_skus – for cross-sells
  • upsell_skus – for up-sells

All columns have the same formatting. To assign a product as related you need to specify its SKU. If you want to assign multiple related products use comma to separate multiple SKUs.

Get sample related product Google Sheet import table

Visit GitHub to get CSV, XML, JSON, XSLX, ODS sample files

Native Magento 2 Import & Export

To experience the native Magento 2 Import & Export with a CSV file proceed to System > Import/Export.

  • Choose the entity type to specify what kind of data will be imported/exported
  • Decide how imported data will behave towards the store data (make sure to limit possible errors to keep default settings intact)
  • Upload a CSV file to import from, or Choose a CSV file type for data export

Improved Import & Export for Magento 2

As it was mentioned above the Magento 2 Improved import & Export module supports various types of import files (CSV, XML, Json, ODS, XLSX) as well as multiple ways of import (file upload, Dropbox source, Google Sheets URL, FTP/SFTP, direct URL, Rest and Soap APIs). These features provide an easy and clear import process but also one of the main gain of the functionality is the automatic data gathering thanks to cron. If scheduled a particular cron job will be run at a specified time or repeated once per predefined period.

Apparently, these constant data updates involve a few more setting fields in the backend but let’s take it slowly and see how it’s done step by step.

Importing related products

Go to System > Import Jobs to import related products, up-sells, and cross-sells to your store content.

  • Select an existing job to edit from the job grid, or add a new one by clicking ‘Add New Job’
  • Enable the job in the General Settings section if needed
  • Name the job
  • Define if the job is run manually, or follow a schedule (you can always set a custom schedule if no present options satisfy you)
  • Connect the job run time and the locale
  • Avoid duplication by automatically generating new URLs
  • Re-index data after import to apply changes seamlessly

NOTE: If there is a need to edit or assign new cron settings you can do it right from the import grid by double-clicking on a job.

  • Allow using API if you are connecting to a particular third-party system
  • Specify the entity type to be imported into (in our case we choose ‘Products’)
  • Indicate where the data are coming from (as the module provides cross-platform import)
  • Clear attributes values or other product characteristics to avoid conflict with the existing database

  • Set up the import behavior to outline the new data and store data relations
  • Plan to stop the job after a certain number of errors if the data is not imported correctly
  • Insert separators for the table content to be read by the system

  • Select a CSV file as an import container
  • Choose an import source (if you use Google Sheets as a source there’s no need to copy & paste the whole CSV table, just insert an URL to the Sheet and the module will upload the data automatically)
  • Insert the path to product images
  • Use advanced mapping settings to overlap product features that are not compatible with Magento 2
  • Set up price rules if there’s a need to manage prices of the imported entities in bulk
  • Save and run the job

Exporting related products

To run an export job go to System > Export Jobs where you can find the grid with all the existing jobs. Add a new export process or open some that were created prior to the moment.

The General Settings resembles the same section for Import Jobs except for two unique options in this case:

  • Define the event that will trigger the job running
  • Divide additional attributes to control the number of the columns in the CSV table

After specifying the entity for export (we export products as it is the type for related products, up-sells, and cross-sells):

  • Enable ‘Consecutive Export’ to minimize the number of entities exported to just the new ones (the entities that were created after the last job run)
  • Assign particular behavior and a source for the export
  • Use filters to export specific entities
  • Save and run the job

As you can see Magento 2 Improved Import & Export adds a bunch of features that makes the import & export processes more diverse and precise. With the help of cron and API, the module provides the latest data for exporting. Multi-platform support guarantees seamless data import from one store to another. Various import and export sources will help you add or download the database from your store in a most suitable format.

Buy Improved Import and Export extension for Magento 2