What's your biggest current challenge? Have your say in Community Polls along the right column.

Disable Buy It Now button for Out Of Stock Products

Disable Buy It Now button for Out Of Stock Products

TE-A-ME
Tourist
8 0 2

How to disable the Buy It Now button for products that are out of stock? 

Replies 6 (6)

topnewyork
Astronaut
761 124 140

Hello,

 

Please share "Store URL"

 

Thanks!

Need a Shopify developer?
Hire us at Top New York Web Design
For Shopify Design Changes | Shopify Custom Coding | Custom Modifications
Try Big Bulk Discount To Boost Your Store Sales with Volume/Tier Discount
TE-A-ME
Tourist
8 0 2

JayAdra
Shopify Partner
178 15 45

We do this automatically in our pre-order app (Early Bird) using Javascript (when we show a back-order or "Notify me" button), but I think it'd be simpler to do this in Liquid if you have some theme coding knowledge.

 

You can find the conditions used to show the Sold out button, and copy that logic to wrap around the Buy it Now button, so it only renders it if the product is in stock.

ZestardTech
Shopify Partner
5912 1067 1413

Hello @TE-A-ME 

Please share your store URL and password.
So that I will check and let you know the exact solution here.

Want to modify or develop new app, Hire us.
If helpful then please Like and Accept Solution .
Email: support@zestard.com
Shopify Apps URL :- https://apps.shopify.com/partners/zestard-technologies
Custom Modifications Into Shopify Theme | Shopify Private App | SEO & Digital Marketing

namphan
Shopify Partner
2054 271 299

Hi @TE-A-ME,

Please send me the code of main-product.liquid file, I will help you check it

Coffee tips fuels my dedication.
Shopify Development Service
PageFly Page Builder Optimize your Shopify store (Free plan available)
Need help with your store? namphan992@gmail.com

Sandy-Stoq
Shopify Partner
77 5 9

@TE-A-ME Your best bet is modifying theme code - you can do it through Javascript or you can hide the button altogether with CSS.

IMO, if you're considering removing the Buy it Now button, you should definitely consider using a preorder flow on the product. Most preorder apps - including STOQ, which we run full time - will automatically hide the Buy it now button on out of stock products that are configured for preorder. So not only do you have the issue of hiding it resolved, you can also get preorders on them and have a chance to get orders in ahead of any restocks. 🙂

STOQ: Recover lost sales with Back in stock alerts & Preorders
Filemonk: Sell digital products & downloads in 3 quick steps

Founder & CEO, Artos Software