How to quickly insert sheet names in cells in Excel?

Is there an easy way to insert the current worksheet's name in one cell? How to insert all worksheets' name in cells? This article will bring you tricky methods to solve these problems.

Quickly insert current sheet name in a cell with functions

Quickly insert all sheet names in cells with VBA

Quickly insert active sheet’s name with Kutools for Excel good idea3

Quickly insert all sheet names with hyperlinks in cells as an index good idea3


Navigation Pane -- Workbook & Sheet (view all open workbooks are list, and all sheets
of the current workbook are list in the pane, you can click the sheet name to switch to it.)

doc navigation list sheet

arrow blue right bubble Quickly insert current sheet name in a cell with functions


Just enter the formula of =RIGHT(CELL("filename",D2),LEN(CELL("filename",D2))-FIND("]",CELL("filename",D2))) in any cell and press Enter key, it shows the current worksheet's name in the cell.
doc-insert-sheets-name-into-cells1

This formula is only able to show current worksheet's name, but not other worksheet's name.

formula Never need to worry about long long formulas in Excel anymore! Kutools for Excel's Auto Text can add all formulas to a group
as auto text, and liberate your brain! Click here to know Auto Text     Click here to get free trial

arrow blue right bubble Quickly insert all sheet names in cells with VBA

If you want to inset all sheet names in cells, VBA macro is a good choice.

Step 1: Hold down the Alt + F11 keys in Excel, and it opens the Microsoft Visual Basic for Applications window.

Step 2: Click Insert > Module, and paste the following macro in the Module Window.

VBA for inserting all worksheets' names in cells:

Sub SheetNames()
Columns(1).Insert
For i = 1 To Sheets.Count
Cells(i, 1) = Sheets(i).Name
Next i
End Sub

Step 3: Press the F5 key to run this macro. Then you will all worksheets' name are listed in Column A of current worksheet. See screenshot:
doc-insert-sheets-name-into-cells2


arrow blue right bubble Quickly insert active sheet’s name with Kutools for Excel

If you want to insert the active sheet’s information including sheet name, workbook name, file path and so on to a cell or header/footer, you can use Kutools for Excel’s Insert Workbook Information.

Kutools for Excel, with more than 120 handy Excel functions, enhance working efficiency and save working time.

After free installing Kutools for Excel, please do as below:

1. Select a cell or a range to put the sheet name, and click Enterprise > Workbook > Insert Workbook Information.doc insert worksheet information 1

2. Then select the workbook information you need to insert from Information section, and specify the location you want to place the information from Insert at section. Then click OK.

doc 1

You can click here to know more about Insert Workbook Information.

Click here to free download Kutools for Excel


arrow blue right bubble Quickly insert all sheet names with hyperlinks in cells as an index

Kutools for Excel's Create List of Sheet Name utility not only inserts all sheet names in cells, but also insert hyperlinks to corresponding sheets too.

Kutools for Excel, with more than 120 handy Excel functions, enhance your working efficiency and save your working time.

After free installing Kutools for Excel, please do as below:

Step 1: Click the Enterprise > Worksheet Tools > Create List of Sheet Names.
doc-insert-sheets-name-into-cells3

Step 2: In the Create List of Sheet Names dialog box, specify the settings according to your needs, and click OK.
doc-insert-sheets-name-into-cells4

Then you will see all sheet names are inserted in a new worksheet, and each sheet name link to corresponding worksheet. See following screenshots:

Worksheet names with hyperlinks
Worksheet names with macro buttons
doc-insert-sheets-name-into-cells5
doc-insert-sheets-name-into-cells6

The Create List of Sheet Name utility makes it easy for you to create a list of all worksheet names of the active workbook in a new worksheet, which contains hyperlinks or macro buttons for quickly navigate to other worksheets. Click to know more about this utility.

pay attention1If you are interested in this addi-in, download the 60-days free trial.

good idea4Combine Worksheets

In sometimes, you may be confused with consolidate or combine multiple sheets/ranges into one sheet or one workbook for some special work, but a powerful utility of Kutools for Excel, Combine Worksheets function can quickly help you handle this job.
doc combine

Recommended Productivity Tools

Office Tab

gold star1 Bring handy tabs to Excel and other Office software, just like Chrome, Firefox and new Internet Explorer.

Kutools for Excel

gold star1 Amazing! Increase your productivity in 5 minutes. Don't need any special skills, save two hours every day!

gold star1 200 New Features for Excel, Make Excel Much Easy and Powerful:

  • Merge Cell/Rows/Columns without Losing Data.
  • Combine and Consolidate Multiple Sheets and Workbooks.
  • Compare Ranges, Copy Multiple Ranges, Convert Text to Date, Unit and Currency Conversion.
  • Count by Colors, Paging Subtotals, Advanced Sort and Super Filter,
  • More Select/Insert/Delete/Text/Format/Link/Comment/Workbooks/Worksheets Tools...

Screen shot of Kutools for Excel

btn read more      btn download     btn purchase

Comments  

Permalink 0 Rizwan
i couldn't get this VBA's last step.
2013-11-19 04:34 Reply Reply with quote Quote
Permalink 0 NAQAASH
I have first sheet (named "DATA"), contains table(column name Location1, Location2 etc).

Second sheet named LOCATOIN-1,

Third sheet name LOCATION-2, and so on and so forth.

Now, in LOCATION-1 sheet, i need to put some data from the table (from "DATA" sheet, column "Location1"). I will take data as it is i mean i will use "=".

How to fetch this data for each sheet... kindly help
2014-01-15 03:54 Reply Reply with quote Quote
Permalink 0 Joeh
Hi...
I think yo can simply use copy from DATA sheet , the paste in LOCATION-1 cell as link. Or you can manually type the address such
='DATA'!$I$105
where 'DATA' refer to sheet that contain source data,$I$105 refer to column I & row 105 which is a cell adress to be linked.


Quoting NAQAASH:
I have first sheet (named "DATA"), contains table(column name Location1, Location2 etc).

Second sheet named LOCATOIN-1,

Third sheet name LOCATION-2, and so on and so forth.

Now, in LOCATION-1 sheet, i need to put some data from the table (from "DATA" sheet, column "Location1"). I will take data as it is i mean i will use "=".

How to fetch this data for each sheet... kindly help
2014-01-18 10:34 Reply Reply with quote Quote
Permalink +1 Macleen
How to display the sheet names in different cell, because this code, just show the sheet names only from cell A1. I want to start it at cell A10.


Sub SheetNames()
Columns(1).Insert
For i = 1 To Sheets.Count
Cells(i, 1) = Sheets(i).Name
Next i
End Sub
2014-06-10 12:56 Reply Reply with quote Quote
Permalink 0 ThaMilkMan
Quoting Macleen:
cell A10.

Sub SheetNames()
Columns(1).Insert
For i = 1 To Sheets.Count
Cells(I + 9, 1) = Sheets(i).Name
Next i
End Sub


Please see the example within quotes to change the starting range.
2016-12-02 09:30 Reply Reply with quote Quote
Permalink 0 Jason Griffith
Hello,
Looks like a great site with lots of helpful information.
I have a question but I don't know if it's possible or not.
I'm trying to make a workbook with a lot of sheets that are linked to one master sheet. All the relevant information will be copied from the master sheet to other sheets.
My question:
Each sheet will named as per employee. If I type all names into one cell in the master can it be copied to the tab (name of sheet)?
For example on the master sheet CELL D2 has 5 employees names and I will have 5 sheets titled with each employees names.
If it's not clear what I'm trying to say I will gladly send my workbook for review.
Many thanks for any help I receive.
2014-06-11 00:12 Reply Reply with quote Quote
Permalink 0 Waqas Mansoor
Great! Saved my day!
2014-08-08 07:26 Reply Reply with quote Quote
Permalink +1 Ahtasham
=RIGHT(CELL("filename"),LEN(CELL("filename"))-FIND("]",CELL("filename")))

First save your file than enter this formula anywhere
2014-11-18 12:09 Reply Reply with quote Quote
Permalink +2 James Rock
this formula you mentioned is not successful because i have many sheets in my file and whenever i apply this formula in one sheet its good but when i apply this formula in multiple sheets it gives only one sheet name in all sheets even i am not doing this while selecting all sheets.

CORRECT METHOD IS :
=MID(CELL("filename",A1),FIND("]",CELL("filename",A1))+1,255)
2015-12-11 11:19 Reply Reply with quote Quote
Permalink +1 Judi
This is excellent... thank you!
2016-09-02 18:44 Reply Reply with quote Quote
Permalink +1 JAMES ROCK
You're most welcome my dear... :)
2016-09-09 10:05 Reply Reply with quote Quote
Permalink +1 Pawan G Nagar
*************** **Thanks a lot************ *****
2016-11-07 04:24 Reply Reply with quote Quote
Permalink +2 GAP
Does anyone know if it is possible to replicate this in Google Spreadsheet?
2015-01-12 14:18 Reply Reply with quote Quote
Permalink 0 Andi2015
So I entered the formula as a function as per instructions above into my spreadsheet and it works. Great, thanks! However it appears I can no longer edit the sheet name on the tab by double clicking as previously. Is this a known and deliberate side effect? How do I edit the sheet name now? I am not a VBA person so basic instructions would be appreciated. many thanks
2015-01-31 12:43 Reply Reply with quote Quote
Permalink 0 Abhijeet
Hi, I have one issue which i am unable to solve is,
How do i display multiple sheets name in respective cells (in list) in a single sheet only?
2015-06-24 12:24 Reply Reply with quote Quote
Permalink 0 Raaj Kanchan
Thanks for the help #Macleen. It helped me a lot. Keep posting such tips. :lol:
2015-08-07 20:23 Reply Reply with quote Quote
Permalink 0 Manish Gupta
Hello,

Can you please help me with the simple VBA code. I have a list of Names in Column A. Specific Range - (A2:A251) - Now I need to create new spreadsheets with these names. The names are driven from a different sheet, thus they keep changing. So in short, if I have 10 names today, they might not appear tomorrow. So on the click of button all older spreadsheets (except 1) should be deleted first and then from the names on the column, new ones should get created.

Please advice if this is possible to do?

Thanks,

Manish Gupta
2016-06-08 07:56 Reply Reply with quote Quote
Permalink 0 Elise Mansour
Can anyone help me with this:
Create a macro that creates 10 sheets and name them Sheet1 to Sheet10 but using a loop
2016-06-23 07:44 Reply Reply with quote Quote
Permalink 0 mohamed ahmed
I have multiple project sheets database with different tab name and this name is shown in master sheet table. which formula can i give that when i insert new tab it should automatically updated in master table.
2016-07-20 13:31 Reply Reply with quote Quote
Permalink 0 Abdul R Shaikh
Great site was very helpful.
I have different tab names and I get the names in one sheet using your code, but it gives names of all the tab names, is there anyway we can add code to select from certain tab number or something like that.
2017-01-31 06:45 Reply Reply with quote Quote

Add comment


Security code
Refresh