Adding Buy Now buttons

Your marketplace includes product description pages with sufficient details to drive purchases. You want an option on the page that directs buyers to checkout.

In this tutorial, you'll use the Storefront API's cartCreate mutation to create a cart with a single variant. You'll embed a Buy Now button on product pages, which opens a new tab with the URL to the online store for checkout.

A gif showing the process of selecting a product variant, clicking the Buy Now button, and being directed to the checkout