Our 2Checkout for WooCommerce payment gateway allows you to accept credit card and PayPal payment from shoppers and users of your e-commerce store.

Our 2Checkout payment gateway support WooCommerce subscription. Mixed Checkout (allowing subscriptions and products to be purchased in a single transaction) is supported.

In this guide, we’ll learn how to set up the plugin and start processing orders and subscription payments via 2Checkout in no time.

First off, buy this plugin then install & activate it.

Login to your 2Checkout account to get your API credentials.

Still on 2Checkout dashboard, click the Webhooks navigation menu, then Settings.

Enter either of the following URL https://example.com/wc-api/WC_2Checkout_Gateway/ or https://example.com/?wc-api=WC_2Checkout_Gateway in Global Settings. Note: only use the latter if you don’t have pretty URL or permalink enabled and be sure to replace “https://example.com” with your website url.

With the above done, click the “Apply button” and then enable all notifications by checking the enable checkboxes.

Finally, click “Save Settings“.

Having gotten your API information, click the 2Checkout sub-section in WooCommerce checkout settings and fill the form with the API credentials.

2Checkout for WooCommerce plugin setup

Below is the description of each setting on the page.

  • Enabled – This will enable the gateway to be used by customers to checkout.
  • 2Checkout Test Mode – This controls what environment transactions are posted to — Enable if you are testing and do not want to be charged. If you intend to use 2Checkout sandbox account, add the code below to your theme’s functions.php file or site specific plugin.

    add_filter('woocommerce_2checkout_enable_sandbox', '__return_true');

  • Title – This is the text shown for the payment during checkout and on the Order Received page.
  • Description – This is the text shown under the title during checkout. Limited HTML is allowed.
  • Account Number – This is your 2Checkout account Number. Learn how to get it.
  • Secret Word – This is your 2Checkout secret word. Learn how to get it.
  • Private Key – This is your 2Checkout private key. Learn how to get it
  • Publishable Key – This is your 2Checkout publishable key. Learn how to get it
  • Checkout Style – This controls how the checkout process works. Choose “Off-site Payment” to redirect customers to the 2Checkout website to complete their payment. Choose “On-site Payment” to keep customers on your website to complete payment.
  • Disable Fraud Review – Check to disable order completion after fraud review. Thus making payment completion instant.

Processing Refunds And Cancelling Subscriptions

Our 2Checkout WooCommerce payment gateway is capable of processing refund from WooCommerce order page and cancelling subscriptions by admin (via the admin dashboard) and customers/users (via My Account page).

Due to limitations of the 2Checkout API, cancellation options inside the WooCommerce admin and frontend interface will only be available if you place a special username and password inside of your  wp-config.php file.

1. Create a new user in your 2Checkout account and give them API access

2. Add the username and password of the newly created user to your wp-config.php file: