Our themes use product tags as "upsell tags" to set up upsell. An upsell tag must be a handle string(only allow letters, "-", "_", no space, no special characters) and have the syntax: "upsell_". Refer to here for more details about the handle string. When users view a product page, products have at least one upsell tag that is identical to the current viewing product's upsell tags will be displayed as upsell products. A product is able to have many upsell tags.
Example: product A has the upsell tags are upsell_fashion, upsell_clothing. When users view this product on the product page. Products have tags upsell_fashion or upsell_clothing will be shown as upsell products.
Upsell products are also shown in the popup cart after a product has been added to the cart.
From your Shopify admin, go to Online Store > Themes.
Find the theme that you want to edit and click Customize.
In the left-hand toolbar, click Theme settings.
Click Upsell products.
Sort random the product list: check or uncheck to show product list sort random.
Enable: check or uncheck to enable upsell in cart popup
Limit: drag and drop to choose product quantity that displayed in cart popup
Enable: check or uncheck to enable upsell in the product page
Limit: drag and drop to choose product quantity that displayed
Enable: check or uncheck to enable upsell in the cart page
Limit: drag and drop to choose product quantity that displayed
Please refer to this guide for more details.