How to Configure Product Variations in WP PayPal

Product Variations is an add-on for the Payment Button for PayPal WordPress plugin (also known as WP PayPal or WordPress PayPal) that can be used to add variations to your PayPal buttons.

PayPal Checkout

The add-on allows you to configure either a simple or a priced variation for a PayPal Checkout button.

Simple Variation for PayPal Checkout

To add a simple variation to a PayPal Checkout button you can use the following shortcode.

[wp_paypal_checkout description="My checkout product" amount="1.99" variation_label="Size:" variation_vals="small,medium,large" variation_options="Small,Medium,Large"]

variation_label

The label for the variation (e.g. Size, Color).

variation_vals

The comma-separated values of the variation.

variation_options

The comma-separated values that will appear to customers in the drop-down list. This is just for display purposes.

a simple product variation added for a paypal checkout button

Priced Variation for PayPal Checkout

To add a priced variation to a PayPal Checkout button you can use the following shortcode.

[wp_paypal_checkout description="My checkout product" amount="1.99" variation_label="Size:" variation_vals="small_1.99,medium_2.99,large_3.99" variation_options="Small 1.99 USD,Medium 2.99 USD,Large 3.99 USD"]

variation_label

The label for the variation (e.g. Size, Color).

variation_vals

The comma-separated elements of the variation in the format of “value_amount” for each option (e.g. value1_amount1,value2_amount2).

variation_options

The comma-separated values that will appear to customers in the drop-down list. This is just for display purposes.

variation with price added for a paypal checkout button

Note: Multiple variations cannot be configured for a PayPal checkout button.

PayPal Payments Standard

Here is a video that shows how it works with a PayPal Payments Standard button: https://www.youtube.com/watch?v=5oWjr4bnf_o

Simple Variation for PayPal Payments Standard

screenshot of a simple product variation in the wp paypal plugin

In order to add a simple variation to a PayPal Payments Standard button you can use the following shortcode.

[wp_paypal button="buynow" name="My product" amount="1.00" on0="Size" os0_val0="Small" os0_val1="Medium" os0_val2="Large"]
screenshot of how to select an option in the wp paypal plugin variation

on0

The name of the variation (e.g. Size).

os0_val0

First option field for the variation. If you have created a variation named “Size” you may want to set this value to “Small”.

os0_val1

Second option field for the variation. If you have created a variation named “Size” you may want to set this value to “Medium”.

os0_val2

Third option field for the variation. If you have created a variation named “Size” you may want to set this value to “Large”.

It is up to you how you want to set up on0, os0_val0, os0_val1 and os0_val2. If you specify the on0 parameter in the shortcode the plugin expects at least one option (e.g. os0_val0).

The shortcode above can be modified to offer color options. For example,

[wp_paypal button="buynow" name="My product" amount="1.00" on0="Color" os0_val0="Red" os0_val1="Blue" os0_val2="Black"]
[wp_paypal button="buynow" name="My product" amount="1.00" on0="Color" os0_val0="Red"]
[wp_paypal button="buynow" name="My product" amount="1.00" on0="Color" os0_val0="Red" os0_val1="Blue"]

You can add up to 10 options. For example:

[wp_paypal button="buynow" name="My Product" on0="Colors" os0_val0="Coral" os0_val1="LightCoral" os0_val2="Salmon" os0_val3="DarkSalmon" os0_val4="LightSalmon" os0_val5="Crimson" os0_val6="Red" os0_val7="FireBrick" os0_val8="DarkRed" os0_val9="Pink"]

Priced Variation for PayPal Payments Standard

screenshot of a priced variation in the wp paypal plugin

If you want to specify a different price for each option you can do so by adding a corresponding amount for it.

[wp_paypal button="buynow" name="My product" on0="Size" os0_val0="Small" os0_val1="Medium" os0_val2="Large" os0_amount0="1.99" os0_amount1="2.99" os0_amount2="3.99"]

os0_amount0

The amount that you want to charge for the first option.

os0_amount1

The amount that you want to charge for the second option.

os0_amount2

The amount that you want to charge for the third option.

screenshot showing how to select a priced option in the wp paypal variation

You can add up to 10 priced options. For example:

[wp_paypal button="buynow" name="My Product" on0="Colors" os0_val0="Coral" os0_val1="LightCoral" os0_val2="Salmon" os0_val3="DarkSalmon" os0_val4="LightSalmon" os0_val5="Crimson" os0_val6="Red" os0_val7="FireBrick" os0_val8="DarkRed" os0_val9="Pink" os0_amount0="1.99" os0_amount1="2.99" os0_amount2="3.99" os0_amount3="4.99" os0_amount4="5.99" os0_amount5="6.99" os0_amount6="7.99" os0_amount7="8.99" os0_amount8="9.99" os0_amount9="10.99"]

The display text by default is OPTION AMOUNT CURRENCY. This can be customized using the os0_option parameters. For example:

[wp_paypal button="buynow" name="My product" on0="Size" os0_val0="Small" os0_val1="Medium" os0_val2="Large" os0_amount0="1.99" os0_amount1="2.99" os0_amount2="3.99" os0_option0="Small $1.99" os0_option1="Medium $2.99" os0_option2="Large $3.99"]

Multiple Variations for PayPal Payments Standard

screenshot of multiple variations in the wp paypal plugin

You can add a second variation (without prices) by using the following parameters in the shortcode.

[wp_paypal button="buynow" name="Buy Now Product" on0="Size" os0_val0="Small" os0_val1="Medium" os0_val2="Large" os0_amount0="1.99" os0_amount1="2.99" os0_amount2="3.99" on1="Color" os1_val0="Blue" os1_val1="Black" os1_val2="Red"]

The second variation can also support up to 10 options. For example:

[wp_paypal button="buynow" name="Buy Now Product" on0="Size" os0_val0="Small" os0_val1="Medium" os0_val2="Large" os0_amount0="1.99" os0_amount1="2.99" os0_amount2="3.99" on1="Color" os1_val0="Blue" os1_val1="Black" os1_val2="Red" os1_val3="Pink" os1_val4="Yellow" os1_val5="Grey" os1_val6="Orange" os1_val7="White" os1_val8="Green" os1_val9="Brown"]

Get the Product Variations Add-on

WP PayPal Product Variations
WP PayPal Product Variations
Set up variations for your WP PayPal buttons.

Note:
* Do not purchase before setting up the core plugin first. The add-on is not at fault if the core plugin does not work on your website.
* Do not purchase if you are not sure about a feature, contact us instead.
* Do not purchase to ask for more features or make the product work in a certain way.
* Do not try to scam us, we take it seriously. We are contributing to the WordPress community with free plugins and themes. If you cannot appreciate this our product is not the right choice for you.
* There is no refund/cancellation as it is a digital product.

Price: $39.99
Price: $29.99

20 thoughts on “How to Configure Product Variations in WP PayPal”

  1. Hello Noor, Are additional variables, up to 8, available with this extension? That is how many product variations I will need. Is there a way to extend it to allow that? Thanks

    Reply
    • @Char, PayPal supports up to 10 options for a variation. The extension supports up to 10 as well.

      Reply
  2. Hello Noor,

    There seems to be some issue where I use the following short code :

    [wp_paypal button="buynow" name="My product" on0="Size" os0_val0="Small" os0_val1="Medium" os0_val2="Large" os0_amount0="1.99" os0_amount1="2.99" os0_amount2="3.99"]

    When we click on the buy now button, it seems to throw up the pricing Blank, where the customer has to put the price.

    Rather then the variation price that it should show up that has been provided.

    Could you please advise!?

    Thanks & Regards

    Reply
    • @Moss, Do you have the WP PayPal Variations extension installed?

      Reply
  3. Can I have more than 3 options for a simple variation?

    Reply
    • @John, Yes.

      Reply
  4. Can you have both size and color variations on the same drop-down?

    Reply
    • @Duane, It is possible. I have updated the documentation.

      Reply
  5. Hello,
    Is this plugin still working on the latest Woocommerce. I cannot see a date when this article was written and therefore don’t know if all of the above is already obsolete. I can tell that there is still no option to add just simple price variations for the same product on Woocomerce.

    Reply
    • @bee, This add-on is not for WooCommerce.

      Reply
      • Granted, but I am using PayPal with WooCommerce. In fact I installed PayPal first.

        Reply
        • @Bee, WP PayPal is the name of the core plugin (there is a link to the plugin on this page). This add-on is for that plugin.

          Reply
  6. Hi,
    Been using the core product for the last 19 months — very good, thank you! And have now just bought this add-on. I may be approaching this the wrong, but my shortcode is below.

    Two questions:
    1) I don’t want the drop down box to default to anything. I have idiot users so they must be forced to choose the correct option and not just see the default first one.
    2) I want the option they choose to be carried through to PayPal. At the moment, I only get the “name” value. Is this possible?

    Thanks for any hep.

    [wp_paypal button="buynow" name="VMCC Dorset Section Xmas Meals 2023" on0="Meal(s)" os0_val0="Member only, 2 Course meal" os0_val1="Member only, 3 Course meal" os0_val2="Member + Guest, both 2 Course meals" os0_val3="Member + Guest, both 3 Course meals" os0_val4="Member + Guest, one 2 Course meal + one 3 Course meal" os0_option0="Member only, 2 Course meal £10" os0_option1="Member only, 3 Course meal £15" os0_option2="Member + Guest, both 2 Course meals £20" os0_option3="Member + Guest, both 3 Course meals £30" os0_option4="Member + Guest, one 2 Course meal + one 3 Course meal £25" os0_amount0="10" os0_amount1="15" os0_amount2="20" os0_amount3="30" os0_amount4="25"]

    Reply
    • @Paul, The data is submitted directly to PayPal. That’s why it’s not possible to render the button without a default option.

      The selected option is submitted to PayPal as well. If you open the transaction in your PayPal account, it should appear under the “Order details” section.

      Reply
      • Thanks for your reply.

        Question 1: OK, I can get around that by setting first option to “—Choose from List Below—” with an amount of 0.01p. They can still press the BIN, but they won’t get an Xmas meal for that!

        Question 2: this is not working for me. I’ve done a full end-to-end test and looked at the transaction in PayPal. I cannot find a section entitled “Order details” but do have a “Purchase details” section but it does not show what Option was chosen.

        If I could upload a image, I could do a screenshot to show you.

        Reply
        • @Paul, Do you see the selected variation if you edit the order under “WP PayPal > All Orders”?

          Reply
          • Yes, in the Data array it is there under [option_selection1] and also at the top of the document as the Variation.

            I’ve just repeated the test on W11 / Chrome on the desktop, and as a buyer, I can see the option if I click the “Details” link in the PayPal popup window *immediately* after approving the purchase. But once I’m finished with this transaction, it seems I can never see the option I chose again. It’s not in the PayPal email that I get as a buyer and it’s in my Activity report for this transaction ID. Clearly a PayPal issue but as a buyer, I would like to know what option I chose.

          • @Paul, Thanks. That means it was submitted correctly to PayPal. The plugin also sends a confirmation email where you can show the value with the {variation} email tag.

  7. I installed the variation plug in, I put the short code into my website, but when a customer selects the shirt size it doesn’t put the shirt size into PayPal. I have no way of knowing what size they picked.

    [wp_paypal_checkout description="MWSPL Everything I DO T-shirt" amount="30.00" variation_label="Size:" variation_vals="small,medium,large,xl,2xl,3xl,4xl" variation_options="Small,Medium,Large,XL,2XL,3XL,4XL"]

    That is the short code I used, what am I doing wrong.

    Reply
    • @Andrew, PayPal doesn’t support variations with Checkout. It will be available in the order added to the plugin’s interface. You can also get the value in the email.

      Reply

Leave a Comment