Is there a shortcut key to switch back and forth between two tabs in Firefox?

For example, you can press CTRL + 1 to select the first tab, CTRL + 2 to select the second. What I want to do is switch between the current tab and the last selected tab. TV remotes have a similar previous or back button that does the same thing. If you only press this one button it will switching solely between two channels each time it is pressed. I see this is called a "last" button on TV remotes.

I know you can move a tab to be right next to each other as tab 1 and tab 2 and then use ctrl + 1 and ctrl + 2 but I'm talking about a switch shortcut.

I'm using Mac.

  • It may be different based on Operating System. Could you add which one you are using? – AMR Aug 31 '15 at 1:10
  • I'm on Macintosh – 1.21 gigawatts Aug 31 '15 at 1:19
  • I made an answer, then reread the question and understood that the posted answer is correct? If so, please mark it as the answer to eliminate confusion. An alternate for switching between tabs would be Ctrl+ Page Down if that's the functionality you're looking for. – DrZoo Aug 31 '15 at 3:30
  • It's acceptable but it's not the exact answer to the question. I left it unchecked because there may be a keyboard shortcut that does what I'm looking for. The solution you posted pulls any open windows apart into a dual view on you can see the content of both windows. It's pretty neat and it would also be acceptable but it's not a toggle switch. – 1.21 gigawatts Aug 31 '15 at 6:32

In order to switch between the two last selected tabs (and to enable Windows like Alt + Tab task switching for Firefox Tabs) you need to

  1. open about:config and
  2. change browser.ctrlTab.previews to true

and you're done. Now you can switch between the last two selected tabs by quickly pressing Ctrl + Tab. If you press Tab repeatedly – or keep Ctrl pressed – you can switch to other tabs too. If you want to cycle the previews in reverse, just throw Shift in there as well.

| improve this answer | |
  • Thank you. Is the keyboard shortcut hard coded? For example, could I change it to ALT + Tab? – 1.21 gigawatts Aug 31 '15 at 10:58
  • Judging by the preference's name you can't change it. There used to be some kind of extension called _Keyconfig _ that allowed changing/defining shortcuts but I'm not sure if it's still working. So I guess you can't. – JC2k8 Aug 31 '15 at 11:04

This should help you out Firefox Keyboard Shortcuts

As I said in my comment it can depend on the operating system you are using for Mac it is command + option + to go backwards and command + option + to go forward in the stack.

| improve this answer | |
  • I do not want to go back and forth in history. I want to switch between two tabs. Going back and forth causes forms to be emptied, pages to reload and other problems. – 1.21 gigawatts Aug 31 '15 at 1:23
  • 1
    Sorry, I think I misunderstood your original question... you basically want a last button. – AMR Aug 31 '15 at 1:23
  • From what I am testing it has nothing to do with history, it just pages between the tabs, and any filled in fields are not changing. – AMR Aug 31 '15 at 1:25
  • 1
    You're right! It is switching between the tabs next to each other! This is good enough for me. – 1.21 gigawatts Aug 31 '15 at 1:27
  • Command + Arrow is back and forward in history. Adding the option lets you navigate through the tabs instead. Glad that works. – AMR Aug 31 '15 at 1:30

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.