Button Not Working on Mobile? 7 Causes and How to Fix Them
Updated October 22, 2026
A button that works on desktop but not when tapped on a phone is usually covered by an invisible element, too small to hit, or broken by a JavaScript error that only happens on mobile. Check what is on top of it in DevTools, look for console errors at phone width, and make targets at least 44 by 44 pixels.
Quick diagnosis
- Nothing happens at all: an invisible element (overlay, closed menu, banner) is on top of the button.
- Works after scrolling a little: a sticky header or bottom bar covers it at its starting position.
- Works on desktop, never on phones: a JavaScript error or a hover-only handler.
- Hard to hit, taps land next to it: the tap target is too small or too close to another link.
Causes and fixes
An invisible element is covering the button
Most commonA transparent overlay, a closed mobile menu that is hidden with opacity instead of display, or a full-width banner container can sit on top of the button and catch the tap.
Fix: Find it with document.elementFromPoint(x, y) in the console. Hide closed menus with visibility: hidden or display: none, and add pointer-events: none to decorative overlays.
A JavaScript error stops the click handler
If a script fails before the button's handler is attached, the button does nothing. Mobile-only errors are common: a slider or analytics script that throws on touch devices, or syntax older mobile browsers do not support.
Fix: Open the console at phone width (or with remote debugging on a real phone) and fix the first red error. Load third-party scripts so their failure cannot block yours.
Tap target too small
Icons and text links that are easy to click with a mouse are too small for a finger. Taps land on the neighbouring element instead.
Fix: Make tap targets at least 44 by 44 CSS pixels with padding, and leave space between adjacent links.
Hover-only interactions
Menus and buttons that reveal their action on :hover or mouseover have no equivalent on touch screens, or need two taps.
Fix: Trigger menus on click or tap, and never hide a primary action behind hover.
Sticky bars covering the bottom of the screen
Cookie banners, chat bubbles, and sticky add-to-cart bars cover whatever sits at the bottom of the viewport, which on mobile is often the button you need.
Fix: Add bottom padding to the page equal to the bar's height and keep floating widgets away from primary actions.
The button is disabled by form validation
A Submit or Add to cart button stays disabled until a required field or variant is selected, but the field is off-screen or hidden on mobile, so the visitor does not know why.
Fix: Show the reason next to the button, scroll to the missing field, and make sure every required field is visible on mobile.
Links inside elements that block touch
Carousels and swipe libraries often call preventDefault on touch events so the slide does not scroll the page, which also cancels taps on links inside slides.
Fix: Configure the slider to distinguish taps from swipes, or update it to a version that does.
How to find it on your site
- 1
Reproduce at phone width
Open the page in DevTools device mode at 375px. Device mode simulates touch, so hover-only bugs show up.
- 2
Ask the browser what is on top
Run
document.elementFromPoint(x, y)in the console with the button's coordinates. If it returns something other than the button, that element is blocking it. - 3
Read the console
Reload with the console open and fix the first red error. One early error can stop every script after it.
- 4
Test on a real phone
Use Chrome remote debugging (Android) or Safari Web Inspector (iPhone) to see errors that only happen on the device.
- 5
Retest the whole path
After fixing, tap through the full journey (product, cart, checkout, contact) at mobile and tablet sizes, with any cookie banner still showing.
Fixes by platform
Shopify
App conflicts and cart drawers are the usual cause on product pages; our add-to-cart guide covers them step by step. Test with the theme preview of an unmodified copy to rule out customisations.
WordPress
Plugin conflicts are the leading cause. Use the Health Check plugin's troubleshooting mode to disable plugins for your session only, then re-enable them one at a time.
Wix and Squarespace
Elements stacked over a button in the editor (a transparent shape or text box) block taps on mobile. Check the mobile editor's layer order.
Custom code
Add an end-to-end test that taps each primary button at 375px with Playwright's mobile emulation; it fails when another element intercepts the click.
Frequently asked questions
Why is a button not working on mobile but working on desktop?
The most common reasons are an invisible element covering the button on small screens, a JavaScript error that only occurs on mobile, a hover-only interaction that touch screens cannot trigger, or a tap target too small to hit accurately.
How do I find what is blocking a button?
In Chrome DevTools, run document.elementFromPoint(x, y) with the button's screen coordinates. It returns the element that will receive the tap. If it is not the button, that element is in the way.
How big should buttons be on mobile?
At least 44 by 44 CSS pixels, which is Apple's guidance, with Google recommending around 48 by 48 and at least 8 pixels between targets.
Why do I have to tap a link twice on iPhone?
iOS treats the first tap as a hover when an element changes on hover, such as revealing a submenu. Trigger menus on tap instead of hover, or remove hover-only effects on touch devices.
Can a cookie banner stop buttons from working?
Yes. A banner fixed to the bottom of the screen covers whatever is beneath it, and some consent tools block scripts until consent is given, which can stop buttons that depend on those scripts.