Accept donations and pay-what-you-want contributions on Shopify

Live demo

Or pick an amount

Each button opens a real checkout on the RedeemID demo store with the amount as a quantity of a $1 product. Look at the cart line, then close checkout without paying.

Shopify has no “enter your own price” field, and a store that already sells merchandise usually wants contributions to go through the same checkout rather than a second payment system. There is a simple way to get both: sell a product that costs $1, and let the quantity be the amount. A $25 contribution is 25 × $1 in the cart. The contributor never needs to know, because your form asks for an amount, not a quantity.

This guide covers the product, the contribution form, a crowdfunding goal tracked with inventory, and how to thank contributors afterwards with a customer tag.

1. Create the $1 product

  1. In Shopify, add a product called Contribution (or Donation, or the name of the campaign).
  2. Set the price to 1.00 in your store currency. Leave Compare-at price empty.
  3. Clear This is a physical product, so checkout asks for no shipping.
  4. Clear Charge tax on this product if contributions aren’t taxable where you sell. Whether a contribution is tax-deductible for the giver is a question for your accountant, not a Shopify setting.
  5. Give the product a product tag such as contribution. Flow uses it later.
  6. Make it available on your Online Store sales channel, and note the variant ID (the number at the end of the variant’s admin URL).

Whole amounts only: a $1 unit can’t make $12.50. Most contribution forms ask for whole amounts anyway.

2. Build the contribution form

The form shows amounts and sends a quantity. Shopify’s cart permalink does the rest: https://your-store.com/cart/VARIANT_ID:QUANTITY opens checkout with that many of the variant, so /cart/1234567890:25 is a $25 contribution.

Preset amounts need nothing but links:

<a href="https://your-store.com/cart/1234567890:10">Give $10</a>
<a href="https://your-store.com/cart/1234567890:25">Give $25</a>
<a href="https://your-store.com/cart/1234567890:100">Give $100</a>

Any amount needs a field and a few lines of script to build the same link:

<form id="contribute">
	<label for="amount">Amount (USD)</label>
	<input id="amount" type="number" inputmode="numeric" min="1" step="1" value="20" required>
	<button>Contribute</button>
</form>
<script>
document.getElementById( 'contribute' ).addEventListener( 'submit', ( event ) => {
	event.preventDefault();
	const amount = Math.floor( Number( document.getElementById( 'amount' ).value ) );
	if ( amount >= 1 ) {
		window.location = 'https://your-store.com/cart/1234567890:' + amount;
	}
} );
</script>

Put the presets and the field side by side and you have the familiar contribution form. It works on a WordPress page or anywhere else you can place HTML.

No script at all is possible too, which is how the live demo at the top of this page works. A plain form posts to the store’s /cart/add with the variant as id, the amount as quantity, and return_to set to /checkout:

<form action="https://your-store.com/cart/add" method="post">
	<input type="hidden" name="id" value="1234567890">
	<input type="hidden" name="return_to" value="/checkout">
	<label for="amount">Amount (USD)</label>
	<input id="amount" name="quantity" type="number" min="1" step="1" value="20" required>
	<button>Contribute</button>
	<button name="quantity" value="25" formnovalidate>$25</button>
</form>

A preset button sends its own quantity after the field’s, and Shopify takes the last one, so the button’s amount wins. Unlike a cart permalink, /cart/add adds to the buyer’s existing cart. Inside a Shopify theme, a product form whose quantity input is labelled as the amount does the same job and lets contributions share a cart with merchandise.

A cart permalink replaces whatever was already in the buyer’s cart, so use it for a dedicated “give” button, and /cart/add or the theme form when contributions should sit alongside other items.

3. Track a goal with inventory

Inventory turns the same product into a crowdfunding counter. Each $1 sold takes one unit from stock, so stock counts down the dollars still needed.

  1. On the variant, turn on Track quantity and set the available quantity to your goal: 5000 for a $5,000 goal.
  2. Turn on Continue selling when out of stock. This one matters: without it, Shopify stops selling at the goal, and a cart permalink for more than the remaining stock is cut to what’s left.
  3. Read the progress from stock: raised = goal − available. Once available goes below zero, you’re past the goal by that much.

On the Shopify product page, Liquid can draw the bar. Keep the goal in a product metafield (here custom.goal) so the template doesn’t hard-code it:

{%- assign goal = product.metafields.custom.goal.value -%}
{%- assign left = product.selected_or_first_available_variant.inventory_quantity -%}
{%- assign raised = goal | minus: left -%}
<progress max="{{ goal }}" value="{{ raised }}">{{ raised }} of {{ goal }}</progress>
<p>${{ raised }} raised of ${{ goal }}</p>

A refund that restocks the item puts the dollars back in stock, so the bar goes down with it. For a stretch goal, add the extra amount to stock rather than starting a new product, so the total keeps counting from the same place.

4. Thank contributors with a customer tag

A contribution is an order like any other, so Shopify Flow can act on it. Add a workflow:

  1. Trigger: Order paid.
  2. Condition: a line item’s product has the tag contribution.
  3. Action: Add customer tags: supporter.

For tiers, add conditions on the line item’s quantity: 100 or more adds patron as well. To end recognition after a year, add a Wait and Remove customer tags, as in time passes.

The tag stays on the contributor’s Shopify customer account, where your email tool and other apps can use it too.

5. Open supporter content on WordPress

This is where RedeemID comes in, after the checkout and not during it. RedeemID connects your WordPress site to Shopify customer accounts, so a contributor signs in to WordPress with the same account they gave with, and the supporter tag arrives with them.

Create a Supporter level for the tag on RedeemID → Access → Levels, then decide what supporters get: members-only posts behind a Membership gate block, a supporters’ category, or a member feature such as ad-free reading or a badge. When Flow removes the tag, access ends with it. The steps are the same as for any purchase; see Turn a Shopify purchase into WordPress membership access.

RedeemID doesn’t build the contribution form, read the order or count the goal. Shopify holds all of that, and RedeemID only reads the tag it leaves on the customer.

Before you launch

  • Discounts: an automatic discount or a store-wide code will discount contributions too. Exclude the contribution product from them.
  • More than one currency: if you sell in several markets, Shopify converts the $1 unit price and can round it. Where your plan allows, set a fixed price for the product in each market; otherwise take contributions in your store currency only.
  • Receipts and reports: the order confirmation shows “Contribution × 25” and the line total. Reports count units sold, which here are dollars.
  • Recurring contributions: monthly giving needs a subscription app with a selling plan on the product, and selling plans don’t work through cart permalinks; use the theme’s product form instead.
  • Try it first: place a test order on a development store and check the stock count, the Flow run and the tag on the customer before you share the form.

Written for: Publishers, Creators

RedeemID is still being built

RedeemID is a WordPress plugin that lets customers sign in with their Shopify account and opens your site to what that account holds. It is in early development, so parts of this site are unfinished and details will change.

It is coming soon. We are looking for sponsors on GitHub and for the first stores and publishers to use it.

For more information, email vinny@vinnysgreen.com.

Get in touch