Use Product Metafields to Control Payment Methods on Shopify

Standard conditions like tags and collections aren't always granular enough. Metafields let merchants store custom data on products and customers, but Shopify has no way to use this data to conditionally show or hide payment methods.

How Payflow solves this

  • Use product metafields like 'custom.no_cod' to dynamically block COD
  • Read customer metafields for VIP tiers, credit limits, or custom flags
  • Build rules that adapt to your unique business logic without code

Setup

  1. 1

    In Shopify admin → Settings → Custom data → Products, create a metafield (e.g. namespace custom, key no_cod, type boolean). Set the value on relevant products.

  2. 2

    Create customization > Hide payment methods.

  3. 3

    Add Product metafield → namespace custom, key no_codEqualstrue.

  4. 4

    Target COD: Pre-definedCash on Delivery.

  5. 5

    Active, Save, and verify at checkout.

Full guide with all options →

Set this up in minutes

Payflow is free to install. No theme edits. No code. Built for Shopify certified.

Install free on Shopify
  • Free to install
  • 50+ conditions
  • Built for Shopify certified
  • No theme edits required