Sell Items from Your Site

Listing individual items on your site is a start, but you can increase the chances of making a sale by letting customers add items directly to their Amazon shopping cart.

Instead of linking directly to product pages or search results [Hack #59], you can let your visitors add items to their Amazon shopping cart, wish list, or wedding registry directly from your site. All it takes is a standard HTML form that’s been modified to include your associate tag and the product’s ASIN.

Add to Cart Button

The goal in sending visitors to Amazon through an associate link is getting them to add items to their shopping cart. With an "add to cart" button, the option for browsing Amazon is bypassed and items are added directly from the associate’s site to the visitor’s Amazon shopping cart.

Add the following code to any HTML page to create a web form button that says “Buy From Amazon.com.”

<form method="POST" 
   action="http://www.amazon.com/o/dt/assoc/handle-buy-box=insert ASIN">
<input type="hidden" name="asin.insert ASIN" value="1">
<input type="hidden" name="tag-value" value="insert associate tag"> 
<input type="hidden" name="tag_value" value="insert associate tag">
<input type="submit" name="submit.add-to-cart" value="Buy From Amazon.com">
</form>

Tip

The fields tag-value and tag_value are both required for you to receive proper referral credit for the item.

Keep in mind that this code displays only the button, not any information about the book. Since you have the ASIN, it’s ...

Get Amazon Hacks now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.