Skip to main content

How to go back to previous/last sheet with shortcut in Excel?

Supposing there are dozens of worksheets in current workbook, and you want to go back to previous or last sheet to copy contents, or for other purposes. But now sheet names are congesting in the Sheet bar, and it’s hard to find out the previous sheet at a glance. So how to go back to previous/last sheet immediately with shortcut? Here are two tricks for you:


Go back to previous/last sheet with VBA

The following VBA code enables you to switch between last used sheet and current sheet in current workbook. You can do as follows:

1. Press Alt + F11 keys to open the Microsoft Visual Basic for Applications window.

2. Double click the ThisWorkbook in the left bar, and then paste the following code into the opening window:

VBA 1: Go back to previous/last sheet

Private Sub Workbook_SheetDeactivate(ByVal Sh As Object)
LastSheet = Sh.Name
End Sub

3. Keep selecting ThisWorkbook in the left bar, and then click Insert > Module, and paste following code into the opening Module window:

VBA 2: Go back to previous/last sheet

Public LastSheet As String
Sub Select_Last()
Application.Sheets(LastSheet).Select
End Sub

You can press F5 key or click the Run button to go back to the last used worksheet at once.

If you prefer to shortcuts to switch between current sheet and last used one, please go ahead:

4. Click Developer > Macros to open the Macro dialog box.

Note: By default the Developer tab does not display in Ribbon, click to know how to show/display developer tab in Excel Ribbon.

5. In the opening Macro dialog box, click to highlight the macro of Select Last, and then click the Options button.

6. In the Shortcut key section, specify shortcut to run this macro of Select Last, and click the OK button to close dialog box.

7. Close the Macro dialog box.

From now on, when you open several worksheets successively, you can press the specified shortcut keys (in our case press the Ctrl + b) to switch between current sheet and last/previous one.


Go back to previous/last sheet by shortcut with Kutools for Excel

If you have installed Kutools for Excel, you can apply its Switch between last and current sheet utility to go back to last sheet with ease in Excel.

Kutools for Excel - Packed with over 300 essential tools for Excel. Enjoy a full-featured 30-day FREE trial with no credit card required! Download now!

Just click the  button in the Navigation Pane or press the Win + A keys simultaneously to switch between current sheet and last/previous one.

Note: After installing the Kutools for Excel, the Navigation Pane turns on by default. If you can’t find out the Navigation Pane, or the  button in the Navigation Pane, you can click the Kutools > Navigation (or View > Navigation) to activate the Navigation pane, and then click the  button in the far left of Navigation Pane.

Kutools for Excel - Supercharge Excel with over 300 essential tools. Enjoy a full-featured 30-day FREE trial with no credit card required! Get It Now


Demo: one click to go back to previous/last sheet


Kutools for Excel: Over 300 handy tools at your fingertips! Start your 30-day free trial with no feature limitations today. Download Now!

Related articles:

Best Office Productivity Tools

Popular Features: Find, Highlight or Identify Duplicates   |  Delete Blank Rows   |  Combine Columns or Cells without Losing Data   |   Round without Formula ...
Super Lookup: Multiple Criteria VLookup    Multiple Value VLookup  |   VLookup Across Multiple Sheets   |   Fuzzy Lookup ....
Advanced Drop-down List: Quickly Create Drop Down List   |  Dependent Drop Down List   |  Multi-select Drop Down List ....
Column Manager: Add a Specific Number of Columns  |  Move Columns  |  Toggle Visibility Status of Hidden Columns  |  Compare Ranges & Columns ...
Featured Features: Grid Focus   |  Design View   |   Big Formula Bar    Workbook & Sheet Manager   |  Resource Library (Auto Text)   |  Date Picker   |  Combine Worksheets   |  Encrypt/Decrypt Cells    Send Emails by List   |  Super Filter   |   Special Filter (filter bold/italic/strikethrough...) ...
Top 15 Toolsets12 Text Tools (Add Text, Remove Characters, ...)   |   50+ Chart Types (Gantt Chart, ...)   |   40+ Practical Formulas (Calculate age based on birthday, ...)   |   19 Insertion Tools (Insert QR Code, Insert Picture from Path, ...)   |   12 Conversion Tools (Numbers to Words, Currency Conversion, ...)   |   7 Merge & Split Tools (Advanced Combine Rows, Split Cells, ...)   |   ... and more

Supercharge Your Excel Skills with Kutools for Excel, and Experience Efficiency Like Never Before. Kutools for Excel Offers Over 300 Advanced Features to Boost Productivity and Save Time.  Click Here to Get The Feature You Need The Most...

kte tab 201905


Office Tab Brings Tabbed interface to Office, and Make Your Work Much Easier

  • Enable tabbed editing and reading in Word, Excel, PowerPoint, Publisher, Access, Visio and Project.
  • Open and create multiple documents in new tabs of the same window, rather than in new windows.
  • Increases your productivity by 50%, and reduces hundreds of mouse clicks for you every day!
Comments (8)
No ratings yet. Be the first to rate!
This comment was minimized by the moderator on the site
First code in a while that doesn't work..
This comment was minimized by the moderator on the site
Good morning sir/madam,Is there any option for change tab automatically after adding some no.s in excel without using keyboard.
This comment was minimized by the moderator on the site
I use ctrl+{ to open the referenced formula cell which is another sheet..i want to go back to the last sheet directly (which is few sheet away from the current sheet) instead of using ctrl+pg up/down..thanks in advance.
This comment was minimized by the moderator on the site
Hi Geebu,
In the first method of this article, you can customize the hotkeys as you need in the step 7. On the other hand, Kutools for Excel’s Navigation Pane is an easy and handy tools to return to last used sheet.
This comment was minimized by the moderator on the site
in this section "Go back to previous/last sheet with VBA" .How can i change the shortcut key to a command button? is there any way?
This comment was minimized by the moderator on the site
Hi Muhammad,
You can assign the VBA for a button in the Quick Access Toolbar.
1. Follow step 1-3 in the first method to add both VBA.
2. Click File > Options > Quick Access Toolbar, select Macros from Choose commands from drop-down list, select the specified macro and add it to the right section. Below screenshot may help you understand it faster.

3. Return to the Excel window, a button assigned to the specified macro is added in the Quick Access Tools.
This comment was minimized by the moderator on the site
This tutorial is helpful, but in the section where it's showing you how to create a macro, I keep getting an error that says "Subscript out of range" in the third line. Do you know what's wrong with this script?
This comment was minimized by the moderator on the site
I keep getting the same error, I would love for this to work!
There are no comments posted here yet
Please leave your comments in English
Posting as Guest
×
Rate this post:
0   Characters
Suggested Locations