# Buy X Get Y

**Example user case:** Offer 50% off one product from the "Accessories" collection when customers buy 3 or more items from the "Clothing" collection.

<figure><img src="/files/mSoC0a78vWQRzpDyt8Kp" alt=""><figcaption></figcaption></figure>

### I. Rule Settings

#### 1.  Choose X (What Customers Must Buy)

Start by selecting the type of items customers need to purchase (X) to qualify for the offer. You have three options:

* **Any items from online store:** Customers can purchase any items available in your store that meet the conditions for the discount.
* **Any items from specific collections:** Customers can purchase any item from selected collections that meet the conditions for the discount.
* **Any items from specific products:** Customers can purchase any item from selected products that meet the conditions for the discount.

<figure><img src="/files/W3tDQIbiEj68tSfGoByR" alt=""><figcaption></figcaption></figure>

#### 2. Set Up Rules

<figure><img src="/files/TEXtl2uxDXYpuRTRmzMG" alt=""><figcaption></figcaption></figure>

**Configure Purchase Conditions (X)**

* Quantity/Amount Range
  * Enter the **"Buy from"** and **"Buy to"** values to define the quantity or purchase amount needed to qualify.
  * Enter 0 in the "Buy to" field if you don’t want to set a maximum limit.

**Define the Discounted Products (Y):** Choose what products (Y) will be discounted or free when the rule is met. You have four options:

* Discount for the Least Expensive Product in X: Automatically apply the discount to the least expensive product from the selected X items.
* Discount for Any Items from the Online Store: Apply the discount to any product available in your store.
* Discount for Any Items from Specific Collections: Apply the discount to any product from selected collections.
* Discount for Any Items from Specific Products: Apply the discount to specific products of your choice.

**Set Discount Details**

* Discounted Quantity: Enter the quantity of discounted products (Y) that customers will receive.
* Discount Value: Choose the type of discount to apply
  * Percent: Discount by a percentage (e.g., 50% off).
  * Fixed Amount: Deduct a specific amount (e.g., $10 off).
  * Free: Offer the discounted products for free.

**Add Multiple Rules**

* Use the **Add** button to create new quantity ranges.
* Click the **Remove** icon to delete a range if needed.

#### 3. Apply to market

Set personalized discount rules for each market or country, tailoring discount values to suit regional needs.

<figure><img src="/files/DXilVHSZIlgWnrvvcE7W" alt=""><figcaption></figcaption></figure>

#### 4. Target customer

Select the specific customer group(s) to apply this discount rule. There are 4 options:

* **All visitors:** Apply this discount to all visitors who browse your website.
* **Logged-in customers:** Apply this discount to customers who are logged into their accounts on your store.
* **Logged-in with tag:** Apply this discount to logged-in customers who have the specified tags assigned to their accounts.
* **Customers without tag:** Apply this discount to all visitors or customers who do not have the specified tags.

<figure><img src="/files/EnLe2btvQalHgYWZ0KVn" alt=""><figcaption></figcaption></figure>

#### 5. Schedule

Set a schedule for this offer to activate and run automatically at the defined time.

<figure><img src="/files/37KN1cq1Vso1iWtWiURj" alt=""><figcaption></figcaption></figure>

### II. Display settings

Customize how discount rules are displayed on your store.

#### 1. Product page

Allows you to set up a discount widget that displays on the product page

* Countdown timer settings

<figure><img src="/files/cOQyoENxqKyeKEXT6DRD" alt=""><figcaption></figcaption></figure>

* Show/hide campaign name

<figure><img src="/files/eWRG9MoJT9DT4qkttkZ4" alt=""><figcaption></figcaption></figure>

* Layout settings

<figure><img src="/files/GszTmfz2r9Osh2MqeBMH" alt=""><figcaption></figcaption></figure>

* Font settings

<figure><img src="/files/qzrwbpp5orAjPQGy9Egz" alt=""><figcaption></figcaption></figure>

* Color settings

<figure><img src="/files/ukVVlSHQoX5sbXqwqUHZ" alt=""><figcaption></figcaption></figure>

* Display on online store:

<figure><img src="/files/9dor4yrXGqPVm9fXdmXd" alt=""><figcaption></figcaption></figure>

#### 2. Pop-up suggestions

Allow you to recommend additional products to customers so they can qualify for discounts.

* Popup display options:
  * **Auto Add Discounted Products to Cart:** Automatically adds the discounted products to the customer's cart without showing the pop-up.
  * **Display a Suggestion Pop-up to Select the Discounted Items:** Displays a pop-up for customers to select recommended products to qualify for the discount.
  * **Not Displayed:** Disables the pop-up suggestion.
* Layout settings

<figure><img src="/files/Rtu7HvaR0WEmNtoN4MNj" alt=""><figcaption></figcaption></figure>

* Product card settings, color settings

<figure><img src="/files/p7uAV72s38LiiwCIuQqP" alt=""><figcaption></figcaption></figure>

* Display on online store:

<figure><img src="/files/2D5VSffK0UD68GI9qzGM" alt=""><figcaption></figcaption></figure>

#### 3. Notice in cart

Allows you to display contextual messages in the cart to guide customers about discounts and gift options

* **Buy more notification:** Encourages customers to add more items to their cart to qualify for the discount.
* **Get gift notification:** Notifies customers that they qualify for a discount but need to choose their discounted items.
* **Change gift notification:** Allows customers to update or change their selected discounted products.

<figure><img src="/files/X9ilvlWffqt2pTcEm7tE" alt=""><figcaption></figcaption></figure>

* Display on online store:

<figure><img src="/files/cxdy9UfgvAhEU4TBo0Sz" alt=""><figcaption></figcaption></figure>

### III. Checkout upsell

Display campaign on the checkout page to increase sales.

#### 1. Active upsell display

<figure><img src="/files/m41QyiMy9NtxE2YkktzR" alt=""><figcaption></figcaption></figure>

#### 2. Add block to theme

<figure><img src="/files/BsXSPPUdLR8ZiTj8R12i" alt=""><figcaption></figcaption></figure>

**3. Customize layout settings**

<figure><img src="/files/8OaL30QQwOsPaHdAk4z5" alt=""><figcaption></figcaption></figure>


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.paretodeals.com/offers/create-an-offer/buy-x-get-y.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
