Adding Affirm as a Buy Now, Pay Later option in WooCommerce checkout

Issue summary:
A WooCommerce site requested integration with Affirm, a popular Buy Now, Pay Later (BNPL) provider, to give customers more flexibility at checkout. The Freshy development team successfully configured Affirm as a new payment method, ensuring smooth compatibility with the existing checkout flow. The integration was completed with a minimum cart total of $35 to qualify for Affirm payments, and the solution was tested to verify that it functioned reliably alongside existing gateways.

Issue background

The client’s eCommerce store wanted to add Affirm as a new payment option to increase conversions and provide customers with alternative financing options. Affirm allows shoppers to split purchases into smaller, manageable payments without traditional credit approval at checkout.

Before this request, the site’s checkout offered only traditional payment options like credit card and PayPal. The client asked for Affirm to be:

  • Fully integrated with WooCommerce checkout.
  • Displayed as a selectable payment method alongside existing gateways.
  • Restricted to orders totaling at least $35.

The Affirm merchant account and credentials were provided to Freshy to facilitate the setup.

Diagnosis

Because the site already used multiple payment plugins, the team took steps to ensure that Affirm could be added without disrupting existing gateways.

Key considerations included:

  • Confirming compatibility between the Affirm plugin and the site’s WooCommerce version.
  • Verifying that Affirm’s sandbox API keys and production credentials were valid.
  • Coordinating 2FA access to the merchant’s Affirm dashboard for configuration and testing.
  • Setting appropriate order minimums to meet Affirm’s transaction requirements.

During testing, it was discovered that the Affirm login credentials initially required 2FA confirmation via the merchant’s phone number. The Freshy team coordinated with the client to gain access and complete setup securely.

Resolution steps

  1. Installed and activated the Affirm WooCommerce plugin
    Used the official Affirm integration from the WordPress repository. Entered API keys provided by the merchant’s Affirm account.
  2. Verified API connectivity and credentials
    Tested connection using both sandbox and live credentials. Confirmed that Affirm checkout scripts loaded correctly on the payment page.
  3. Configured Affirm checkout rules
    Set the minimum order total to $35 per client request. Enabled sandbox testing mode to validate transaction flow. Ensured Affirm appeared in the correct order within the payment gateway list.
  4. Tested checkout functionality
    Placed multiple test orders to confirm that Affirm appeared only when the cart total met the $35 minimum. Verified that Affirm redirect and confirmation screens worked as expected. Checked that completed orders synced properly within WooCommerce.
  5. Finalized and deployed changes
    Disabled sandbox mode and enabled live credentials. Deployed changes to production and confirmed Affirm visibility in live checkout. Informed the client that Affirm was active and fully functional.

Final outcome

Affirm was successfully added to the WooCommerce checkout page, functioning alongside existing payment methods without any conflicts.

Results:

  • Affirm now appears as an active Buy Now, Pay Later payment option.
  • Orders under $35 automatically hide the Affirm option.
  • Checkout operates smoothly with Affirm’s hosted payment flow.
  • Customers gain access to flexible payment terms, improving conversion potential.

Key takeaways

  • Affirm integration adds value by offering customers accessible financing options that can increase sales.
  • Setting a minimum order threshold helps ensure Affirm compliance and improves payment gateway organization.
  • Collaboration between developers and merchants is key for managing secure API credentials and 2FA authentication.
  • Always test BNPL integrations in sandbox mode before deploying live to avoid checkout disruptions.

If your WooCommerce site needs new payment gateway options or Buy Now, Pay Later integrations like Affirm, contact the Freshy team for expert eCommerce development and integration support.