Delete a button only on mobile

Topic summary

Remove a single large button from the homepage on mobile only, while keeping it on desktop, in a Shopify store using the Dawn theme.

  • An initial fix was suggested by adding custom code in theme.liquid (before ). A result image was referenced, but the exact code snippet is not visible here.
  • After applying the fix, all buttons on the mobile homepage were hidden, not just the first “big” button the requester wanted to remove.

Current issue: The solution’s selector/scope is too broad on mobile, affecting all buttons rather than the targeted one.

What’s needed: A refined, targeted approach (e.g., a more specific selector tied to the first button/section) so only that specific button is hidden on mobile.

Status: Unresolved/ongoing. The requester has asked for an adjustment to limit the change to the first homepage button on mobile. Code and image references are central, but the actual snippet is not included in the thread excerpt.

Summarized with AI on December 18. AI used: gpt-5.

Hello,

I want to delete this big button on my home page but only on the mobile website, I want to keep it for the desktop users !

I use dawn theme and this is my website: womber.fr and the password is PROPAGANDAAA

Thanks for your help !

1 Like
  • Here is the solution for you @PAUL8
  • Please follow these steps:
  1. Go to Online Store → Theme → Edit code.
  2. Open your theme.liquid file
  3. In theme.liquid, paste the below code before and press ‘Save’ to save it

  • Here is the result you will achieve:

  • Please press ‘Like’ and mark it as ‘Solution’ if you find it helpful. Thank you.

Thank you so much !

1 Like

Glad to help you. Have a good day.

Can you help me, because it deleted all the buttons on mobile of the home page? But I just wanted to delete the first of the page.

Thanks !

Can you help me, because it deleted all the buttons on mobile of the home page? But I just wanted to delete the first of the page.

Thanks !