535

Chrome supports two-finger swipes left/right in order to browse back/forward in the browser history. Unfortunately, Chrome handles this differently to other macOS applications, and it's far too easy to accidentally trigger it while you're in the middle of a long down/up scroll, which needless to say occurs often.

I generally like the gesture, and things like Preview, Safari, and other application have implemented it much better, where you cannot blindly navigate back/forward so long as you have begun to scroll up/down.

How do I selectively disable two-finger back/forward navigation in Chrome?

Jason Salaz
  • 24,471
  • 15
    This sounds like a poor implementation on Chrome's part. Have you considered filing a bug? – jtbandes Aug 09 '11 at 22:43
  • Actually, I just tried to reproduce this and it doesn't seem to be happening for me in the latest dev build. Are you sure you're up to date? – jtbandes Aug 09 '11 at 22:45
  • I'm on the latest dev build and I can confirm this error. I would file a bug with the Chrome team. http://code.google.com/p/chromium/issues/list – Nathan Walker Aug 09 '11 at 23:50
  • If you don't have to be on the dev version, it's less sensitive in the beta channel – bringel Aug 10 '11 at 13:38
  • 3
    That's not a suitable answer by virtue of the fact that (in theory), any other channel will eventually have the current state of the dev channel. – Jason Salaz Aug 10 '11 at 16:37
  • 5
    It's also easy to do if the page is wide and you are simply trying to scroll all the way back to the left. – Michael May 13 '16 at 20:08
  • 3
    100 million times ^ – Jason Salaz May 13 '16 at 23:30
  • 4
    Judging by the number of votes and views on this page, this should be disabled by default. – rouble Jun 21 '18 at 02:46
  • 1
    Please up vote this defect: https://bugs.chromium.org/p/chromium/issues/detail?id=854881 – rouble Jun 21 '18 at 02:57
  • 5
    The only time I've ever used this feature is by accident – Omar Shishani Aug 06 '22 at 06:32
  • 1
    It also makes lateral scrolling impossible – Rónán Ó Braonáin Apr 19 '23 at 07:42
  • Chrome's god awful horizontal scrolling behavior makes lateral scrolling difficult. I asked this question and wanted to turn it off because (1) 90% of the desktop web doesn't require horizontal scrolling (and even less of the mobile web), and (2) it is that Chrome's implementation of it is so poor that when I want to horizontally scroll, I wind up navigating back instead which completely screws up page state. I can still do shift+scroll to do horizontal, which is way better, and dealing with a "why isn't horizontally scrolling working?" moment is acceptable to remind me to do that instead. – Jason Salaz Apr 20 '23 at 21:01
  • 1
    Just to note that this bug report listed by @rouble was marked as "Won't do" after 3 years of inattention. – Paul Childs Sep 12 '23 at 00:14

8 Answers8

579

I know its over a year later, but I had the same question, and then figured out the answer myself.

Open terminal and type:

defaults write com.google.Chrome AppleEnableSwipeNavigateWithScrolls -bool FALSE

Then restart Chrome.

Now you can have it enabled system wide, and just disabled for chrome. By the way, this works for any app, just replace com.google.Chrome with the bundle identifier of the target app.

If your interested in how it works, the AppleEnableSwipeNavigateWithScrolls is the global setting, that can be overwritten for any specified app.

Hope this helps someone in the future.

  • 38
    Oh yes. Oh my god yes. This is EXCELLENT. It helped me, NOW. THANK YOU! – Jason Salaz Jan 28 '13 at 03:00
  • 27
    I want to create a hundred accounts just to keep upvoting this answer as many times as humanly possible. – Scott Jul 16 '13 at 13:11
  • 8
    Works for me on Mavericks without the .plist – Billy Moon Nov 12 '13 at 11:06
  • How to make it automatic? (For me it works, but after system restart I need to do it again.) – Piotr Migdal Nov 26 '13 at 11:47
  • You never need the .plist. Can you remove that part of the answer? – interestinglythere Feb 05 '14 at 06:01
  • 6
    Tried this in Yosemite and it doesn't seem to work (even after restarting Chrome). This is super annoying - especially when I am entering information (say, writing an answer on SE), and scroll to check something - it's rather easy to end up going back, and losing your edit. Does this answer need an update for Yosemite? – Floris Dec 29 '14 at 15:52
  • We need to be able to control this behavior in the web app (We're building an app that has a horizontally scrolling layout)... – Steven Lu Mar 11 '15 at 16:40
  • This worked for me in Yosemite and Chrome 41 - but I was trying it with a magic mouse so had to use @fredy-muñoz answer... – Mladen Mihajlovic Mar 18 '15 at 16:36
  • Worked for Chrome 44 in Yosemite 10.10.4 with a Bluetooth Logitech mouse. – tar Aug 04 '15 at 14:30
  • So much better! Worked for me on Chrome Version 45.0.2454.101 (64-bit) on OS X Yosemite 10.10.5. – cbare Oct 06 '15 at 23:19
  • This stopped working for me, but then I realized that Chrome was in the middle of an update and needed to be restarted (Chrome > About Google Chrome > Relaunch). – KenHaggerty Oct 27 '15 at 21:21
  • 4
    For Yosemite + Chrome latest stable 47.0.2526.106 (64-bit):

    defaults write com.google.Chrome AppleEnableSwipeNavigateWithScrolls -bool FALSE

    works perfectly for me after restarting Chrome.

    (Note previous answers mentioned defaults write com.google.Chrome.plist AppleEnableSwipeNavigateWithScrolls -bool FALSE but the extraneous .plist suffix made it a NOOP.)

    – cweekly Jan 07 '16 at 19:24
  • 3
    Awesome! Works for Safari too!!! defaults write com.apple.Safari AppleEnableSwipeNavigateWithScrolls -bool FALSE. Just what I was looking for. Two-finger swipe is also for horizontal scroll and scrolling in a text area that contains an oversized image can initiate the "back button" which obliterated my work filling out the form. Not cool. They should make it 3-finger or something at least. – hepcat72 Apr 21 '16 at 14:00
  • This worked for me after I restarted my computer. – dinosaur Jul 23 '16 at 07:32
  • I know this is the opposite of what the question asked, but I just used this to enable two finger swipe to go back by switching FALSE to TRUE like so: defaults write com.google.Chrome AppleEnableSwipeNavigateWithScrolls -bool TRUE – Logan Besecker Oct 05 '16 at 18:59
  • 3
    Works on El Capitan and Chrome Version 55.0.2883.95 (64-bit). Had to completely quit Chrome and restart it. No system reboot needed. – km1 Jan 06 '17 at 18:27
  • Still working on Sierra (10.12.5) and Chrome 59.0.3071.115. Thank you! – Paulo Casaretto Jul 04 '17 at 18:03
  • Worked for me on Sierra and Chrome Version 62.0.3202.94 (Official Build) (64-bit). Thanks a ton!!! – Ward W Dec 06 '17 at 21:51
  • 2
    Saved my day. Finally disabled the most hated feature. – Jianwu Chen Apr 08 '20 at 23:11
  • For me this was the only way that worked. – Mark Oct 15 '20 at 10:14
  • how do i find out the bundle identifier of the target app? Asking because I am using Brave Browser which is based on Chrome – cryanbhu Oct 30 '20 at 07:21
  • Still works for Big Sur! – 夏期劇場 Apr 01 '21 at 02:35
  • Still works on Chrome 89! – jameshfisher Apr 01 '21 at 09:12
  • 2
    Edge users: defaults write com.microsoft.edgemac AppleEnableSwipeNavigateWithScrolls -bool FALSE – Bruno Lemos Jun 24 '21 at 00:19
  • not working in windows 10 – khiav reoy Aug 02 '21 at 04:43
  • 1
    For Brave Browser: defaults write com.brave.Browser AppleEnableSwipeNavigateWithScrolls -bool FALSE – Mike Richards Oct 28 '21 at 19:53
  • 1
    If you don't want to use a terminal you can navigate to chrome://flags and set Overscroll History Navigation" to Disabled

    chrome://flags/#overscroll-history-navigation

    – Perchik Mar 04 '22 at 03:02
  • This is the money! – dustbuster Apr 15 '22 at 17:23
  • 1
    Worked in 2023. Thanks – Charith Jayasanka Mar 16 '23 at 05:58
  • Works great with Arc too: defaults write company.thebrowser.Browser AppleEnableSwipeNavigateWithScrolls -bool FALSE – Andres Riofrio Sep 06 '23 at 00:41
233

I went into the System Prefs and changed the Page change gesture from two fingers to three (OSX Lion). The three finger swipe seems to be more responsive at any rate and I'm usually only using two fingers for everything else.

System Preferences > Trackpad > More Gestures > Swipe between pages

callum
  • 560
raydeen
  • 2,339
  • 30
    ...this works, though you're also changing the setting for every other app (including Preview). I like this solution and it's what I'm doing, but I'm hoping the Chrome people will read this thread and see that they need to offer a fix within the browser. – Eric Mar 27 '12 at 17:04
  • 1
    Also works for Mountain Lion. – Nakilon Aug 04 '13 at 16:56
  • 4
    IMHO this is a better solution than changing the Chrome defaults with the command line command. – Steve Bennett Nov 26 '14 at 02:13
  • 2
    Works in Mavericks when the command line option did not. – atwixtor Dec 12 '14 at 15:12
  • Works fine in Yosemite also. Some people might like the swiping/gesture stuff but I don't really, so I changed it to three-finger swipe (which should avoid false positives). – Per Lundberg Jul 23 '15 at 19:59
  • Thanks for your hint! I love the two finger gesture for navigatin the browsind history and used it ever since. But now, as I used floor planning web apps such as http://community.planningwiz.com/ and http://www.homestyler.com/floorplan with their 2D/3D views, where the gesture is used for view panning, I had triggered the history back action accidentially way too often, which was annoying as it always exited the app back to the home screen and thereby discarded my work... So I needed a temporary deactivation while working with these apps. Thanks! – porg May 30 '16 at 18:30
  • You saved my day. Command option didn't work for me in El Capitan – Sergiy Seletskyy Jun 10 '16 at 18:21
  • 1 finger makes all the difference!! – cryanbhu Oct 30 '20 at 07:23
  • I turn off all gestures, as I just realized I never use any of them. – John Jiang Nov 29 '22 at 06:53
62

Summary:

It looks like Google Chrome uses Apples default gestures, so by disabling Apples gestures you disable Chromes. However, you probably still love some gestures like I do. For that get BetterTouchTools.

Disable Google Chromes Gestures

You can disable chromes gestures by going to System Preference > Mouse OR Trackpad > More Gestures > and uncheck Swipe between pages.

Keep the Gestures You Want

I still love gestures so I downloaded BetterTouchTools which allows me to make the gestures I want. I disabled all apples gestures then created my own. You can get very custom with gestures this way. Or if you prefer, leave some of apples gestures on and use BetterTouchTools for the more custom ones.

zechdc
  • 2,132
  • 2
  • 17
  • 15
  • How do you enable the Swipe between pages gesture for other applications?? The gesture is missing in the BetterTouchTools. – Petr Peller Sep 26 '12 at 13:48
  • @PetrPeller Each application should have its own keyboard shortcut for swiping between pages. In BetterTouchTools you can setup custom gestures for each application. Setup an new application, use whatever gesture you want for a swipe, then enter that applications keyboard shortcut for the gestures action. Make sense? – zechdc Sep 26 '12 at 15:50
  • @zechdc But that way I would have to set up every single application separately and I would miss the animation as the gesture would be translated into keyboard shortcut. It's a pity that the BetterTouchTools can't just disable the 2-finger swipe gesture for Google Chrome and leave default behaviour for different apps. – Petr Peller Sep 26 '12 at 18:04
  • @PetrPeller I agree. Sorry I can't be of more help. – zechdc Sep 26 '12 at 20:50
  • Can you disable the two finger horizontal swipe gestures on a per app basis with BetterTouchTools, i.e. to disable this for Chrome only, but still use it in Preview.app, Safari, etc? If not, with which other tools or with which config file tweaks or command lines? – porg May 30 '16 at 18:25
  • @prog You cannot disable system default gestures with BetterTouchTools. You can only add additional gestures. My recommendation is to disable Mac's default gestures, then create your own. You can create new gestures on a per app basis. For example, you can setup a swipe action in BTT to use the CMD + [ hotkey which will make safari go back in history one page. Does that make sense? – zechdc May 31 '16 at 23:27
  • love this option, gestures are useful, it's just a conflict when I'm scrolling horizontall and I reach the boundary, so it thinks I'm trying to navigate. I've changed it to a 3-finger swipe, so I still have a quick gesture. Thanks! – Tiago Mar 30 '17 at 09:33
  • This doesn't answer the question directly, plus it looks like advertising. BetterTouchTools is a commercial software. – David Ammouial Aug 26 '20 at 20:06
  • 1
    @DavidAmmouial, true. When I wrote this answer BetterTouchTools was free. I no longer use it because this hasn't been an issue for more anymore. At the time, 9 years ago, it worked well. – zechdc Sep 06 '20 at 03:57
50

There are two different properties, one is for the Trackpad: AppleEnableSwipeNavigateWithScrolls, the other is for the Mouse/Magic Mouse: AppleEnableMouseSwipeNavigateWithScrolls.

So you need to execute one or both of these commands:

defaults write com.google.Chrome AppleEnableMouseSwipeNavigateWithScrolls -bool false
defaults write com.google.Chrome AppleEnableSwipeNavigateWithScrolls -bool false
simPod
  • 185
Fredy Muñoz
  • 611
  • 5
  • 4
  • 2
    Thanks so much for this! Couldn't figure out for the life of me why this was working for everyone else but me—it was because I'm using a Magic Mouse and needed AppleEnableMouseSwipeNavigateWithScrolls. – Derek Shockey Apr 10 '19 at 19:57
  • This is the answer needed if you're using an Apple Magic Mouse 2. – Simone Manganelli Aug 29 '20 at 07:29
  • awesome, I almost got crazy about this, when some pages needed vertical scrolling and instead it navigated ... – Karl Adler Sep 05 '20 at 11:30
14

I also tried the terminal command on Yosemite, it didn't work for me.

And then I tried uncheck "Swipe between pages" in mouse settings, and it worked.

enter image description here

Chris
  • 149
  • 3
    It didn't work for you since you are using a Magic Mouse, and not a Magic Trackpad. Note @Fredy-Muñoz's answer. The instructions in this answer disable the feature for all apps. If this works for you, great. However, in my post / the original Question, I asked about selectively disabling it for Chrome. See the accepted answer or Fredy's for more information. – Jason Salaz Oct 19 '15 at 11:22
14

Chrome Canary users should use:

defaults write com.google.Chrome.canary AppleEnableSwipeNavigateWithScrolls -bool FALSE
allieferr
  • 103
Lloyd
  • 271
  • 2
    During my testing the com.google.Chrome.canary.plist should be com.google.Chrome.canary. – darkbaby123 Sep 05 '14 at 03:08
  • I used com.google.Chrome.dev to enable it on the dev version (which now has it disabled by default) thanks for the inspiration – Sodj Dec 14 '20 at 18:40
9

This is available as the #overscroll-history-navigation flag in chrome://flags

Overscroll history navigation
History navigation in response to horizontal overscroll. – Windows, Linux, Chrome OS

#overscroll-history-navigation

There is an option called "disable click" on that. Then just restart Chrome.

Alper
  • 3,936
ti7
  • 221
6

The only way I'm currently of is two disable two-finger page swiping system-wide, from the Trackpad section of System Preferences. I wait patiently for Chrome to either fix its implementation, or at least provide an app preference for disabling the feature.

  • 1
    I don't expect them to ever fix this. They've been arguing in favor of an even stupider mis-feature for years, where hitting the [delete] key will go back a page if no fields have focus. From a usability perspective, Chrome is a steaming pile . It's main redeeming factors are (1) a superior Inspector, and (2) more and better extensions. Otherwise it would be worthless. – iconoclast Dec 02 '15 at 23:19