Download Practice Workbook
Example 1 – Use the Home Tab
- Click the sheet you want to delete. Keep it as the active sheet.
- Go to the Home tab and click Delete.
- Select Delete Sheet.
- Click Delete in the prompt.
The Use_Home_Tab worksheet is deleted.
Example 2 – Use the Context Menu in the Sheet Tab
- Right-click the sheet.
- Select Delete.
- Click Delete in the prompt.
The Apply_Context_Menu sheet is deleted.
Example 3 – Use the Navigation Pane in theView Tab
- Click the View tab.
- Select Navigation.
- Select Use Navigation Pane.
- Click Delete.
- Click Delete in the prompt.
The worksheet is deleted.
Example 4 – Use Keyboard Shortcuts to Delete a Sheet in Excel
4.1 Use a Keyboard Shortcut
- Select the sheet.
- Press Alt and hold.
- Press H + D + S one by one.
- Click Delete in the prompt.
The selected worksheet is deleted.
4.2 Use the Legacy Keyboard Shortcut
- Select the sheet.
- Press Alt and hold.
- Press E and L.
- Click Delete in the prompt.
The worksheet is deleted.
Example 5 – Right-Click and use the Keyboard
- Right-click the sheet you want to delete.
- Press D.
- Click Delete in the prompt.
Read More: Shortcut to Delete Sheet in Excel
How to Delete Multiple Sheets in Excel?
1. Use the Home Tab
- Press and hold Shift.
- Select the sheets one by one.
- Click the Home tab >> select Delete.
- Click Delete Sheet.
2. Use the Mouse and the Keyboard
2.1 Press Shift and Right-click to delete Adjacent Sheets
- Press and hold Shift and select the sheets you want to delete.
- Right-click.
- Select Delete or press D.
The selected sheets will be deleted.
2.2 Press Alt and Right-click to delete Non-Adjacent Sheets
- Press Alt and hold to select non-adjacent sheets.
- Select the sheets you want to delete and right-click.
- Select Delete or press D.
The selected non-adjacent sheets will be deleted.
Read More: How to Delete Multiple Sheets in Excel
Can I Use VBA to Delete Sheets in Excel?
Launch the VBA Editor:
- Go to the Developer tab. If you don’t have the Developer tab on the Ribbon, enable it in Excel Options.
- Select Visual Basic.
- Enter the VBA code in the code window.
- Select Insert and add a new Module.
1. Delete the Active Sheet
Sample_Dataset is the active worksheet.
- Enter the code in the VBA editor window.
Sub Delete_active_sheet()
Application.DisplayAlerts = False
ActiveSheet.Delete
Application.DisplayAlerts = True
End Sub
- Run the code by pressing F5.
The active sheet is deleted.
2. Delete a Sheet by Name
- Sales_Data is the active sheet.
- Copy this code into the VBA editor.
Sub delete_sheet_by_name()
Application.DisplayAlerts = False
Sheets("Sales_Data").Delete
Application.DisplayAlerts = True
End Sub
- Run the code.
The Sales_Data sheet is deleted.
3. Delete Sheets with a Specific Text in the Sheet Name
The workbook contains 4 Sheets with sales and product details in 2020 and 2021. To delete all sheets containing “2020”:
- Copy this code into the VBA editor.
Sub DeleteSheetsWithSpecificText()
Dim ws As Worksheet
Dim searchText As String
Dim wsToDelete As Worksheet
' Define the text you want to search for in sheet names
searchText = "2020"
' Loop through all worksheets in the workbook
For Each ws In ThisWorkbook.Worksheets
' Check if the sheet name contains the specified text
If InStr(1, ws.Name, searchText, vbTextCompare) > 0 Then
' Set the sheet to delete
Set wsToDelete = ws
' Delete the sheet without confirmation
Application.DisplayAlerts = False
wsToDelete.Delete
Application.DisplayAlerts = True
End If
Next ws
End Sub
- Press F5 to run the code.
The two sheets containing “2020” are deleted.
4. Delete All Sheets Except the Active Sheet
- Copy this code into the VBA editor.
Sub Delete_sheets_except_active_sheet()
Application.DisplayAlerts = False
For Each ws In Worksheets
If ws.Name <> ActiveSheet.Name Then
ws.Delete
End If
Next ws
Application.DisplayAlerts = True
End Sub
- Run the code and all sheets will be deleted, except the active sheet.
Frequently Asked Questions
1. How do I Delete all data in a sheet?
Answer: Select all cells in the sheet. Click the upper-left corner of the sheet. Right-click the selected cells and choose”Delete“.
2. How to insert a sheet in Excel?
Answer: Click the “+” sign beside the existing sheets.
3. Why can’t I delete a sheet in Excel?
Answer: Possible reasons:
- The sheet is protected. To unprotect it, go to the “Review” tab >> click “Unprotect Sheet,” >> enter the password if required.
- If the sheet you want to delete is hidden, unhide it. Right-click any sheet tab, select “Unhide,” >> choose the sheet you want to delete.
- If there is a macro in your workbook that prevents sheet deletion, you need to modify the code.
- The workbook is shared and deletion is restricted.
Delete Sheet in Excel: Knowledge Hub
- How to Delete All Sheets in Excel Except One
- How to Delete Hidden Sheets in Excel
- How to Undo Delete Sheet in Excel
- [Fixed!] Delete Sheet in Excel Not Working
<< Go Back to Worksheets | Learn Excel
Get FREE Advanced Excel Exercises with Solutions!