I frequently have Terminal open with several tabs. I have noticed that sometimes switching to a new tab takes several minutes, during which Terminal appears to hang with a busy cursor.

I suspect that cause is running programs in that tab with very verbose debug output, that is producing extremely long lines. I know that sometimes there are single lines with megabytes of text in them, and it's possible that the lines have tens or hundreds of megabytes.

One solution to the problem is to run those commands as command_with_long_output | cut -c 1-1000, but I have a tendency to forget to do that, especially if I'm switching from running a test data set (where the lines are maybe a few kilobytes) to running the full data set.

I'm hoping for a setting of "Only keep 1M of data" or "Only keep first 20k characters per line", but I don't see anything like that.

  • command-K clears the scroll back of a window. I do that when Terminal gets slow.
    – lhf
    Commented Sep 25, 2020 at 20:58
  • command-k is useful, but I do have to wait for the app to become responsive before I can use it Commented Sep 30, 2020 at 16:22

1 Answer 1


Go to Terminal / Preferences / Profiles / Window / Scrollback / Limit the number of rows to:

enter image description here

You must log in to answer this question.

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