I recently rebuilt my system and everything works except I can't scroll my (iterm2) terminal window back to look at commands and output that have scrolled off the screen.

Without tmux I can scroll but with tmux I can't

When using vim this isn't an issue as I can scroll back within vim.

For basic terminal (which I don't normally use) the behavior is a little different in that the current line scrolls back to show previous commands, but just that line, not the whole window.

My terminal settings include: enter image description here

I do use tmux and I have a detailed .tmux.conf However I have removed these settings, applied with tmux source-file ~/.tmux.conf,. seen the changes applied (back to default tmux setting) and still have the issue

My settings include

set -g mouse on

4 Answers 4


The recent release of tmux 2.1 changed some of the configuration options. This bit of code (taken from here) restores the previous functionality:

bind -n WheelUpPane if-shell -F -t = "#{mouse_any_flag}" "send-keys -M" "if -Ft= '#{pane_in_mode}' 'send-keys -M' 'select-pane -t=; copy-mode -e; send-keys -M'"  
bind -n WheelDownPane select-pane -t= \; send-keys -M 

Add/place these in the ~/.tmux.conf file

Apply with tmux source-file ~/.tmux.conf

  • Great. Updated to mention `.tmux.conf`` Commented Dec 13, 2015 at 15:46
  • 4
    Works on one mac and one Ubuntu machine without errors but another mac says unknown unknown key: WheelUpPane and unknown key: WheelDownpane it has the same osx version (Yosemite) and has same version of iterm2 (2.1.4) and tmux (1.9a) Commented Dec 13, 2015 at 17:27

One cause of this is the "Secure Keyboard Entry" feature of iTerm.

To solve this problem, you can go with iTerms -> Secure Keyboard Entry, and de-select that item.

enter image description here

I came across this issue with my Logitech MX Master 2S as well, and unfortunately other solutions mentioned here didn't work to me.

  • oh this one worked for me with the MX Master 2S, why would that secure keyboard entry option ever disable scrolling with the mouse wheel. Thanks :) Commented Sep 21, 2020 at 21:58
  • It's 2021 and this still works / is still broken with the MX Master 3 and iTerm2 3.4.4 :-/
    – opstastic
    Commented Mar 24, 2021 at 21:00

In iTerm2 all you need to do is to go to Preferences > Profile > Terminal and check ‘Save lines to scrollback when an app status bar is present’.


In my case, I enabled “Mouse Reporting” on iTerm2. Under iTerm Preferences -> Profiles -> Terminal Setting, tick the "Enable mouse reporting" checkbox.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .