- Excel 365
- Excel 2021
- Excel 2019
- Excel 2016
- February 12, 2022
- 25 Comments
Sometimes Excel’s sorting and filtering options become grayed-out and unusable for no apparent reason. This problem doesn’t arise very often, but it can be very confusing when it does.
Adding to the confusion, there are several reasons why this can happen! This article explains the reasons sorting and filtering can be disabled, and how to fix the problem.
The worksheet may be Protected
One of Excel’s features is the ability to ‘protect’ a worksheet, which can prevent it from being sorted, and even prevent it from being changed in any way.
If this is the cause of the problem, you should be able to resolve it by unprotecting the worksheet.
Worksheet protection is covered in depth in our Expert Skills course.
A worksheet group may be selected
Excel allows you to make changes to multiple worksheets at the same time by selecting multiple worksheets before making changes. This is called a ‘worksheet group’.
You cannot use sorting and filtering when multiple worksheets are selected, so if this is the cause of the problem you can fix it by simply selecting a single worksheet.
Worksheet groups are covered in much greater depth in our Essential Skills course.
The data may be partially contained within a Table
This is an unusual circumstance, but it could be very difficult to resolve without knowing about the possibility!
Modern versions of Excel allow you to define parts of a worksheet as Tables, which enables many advanced features to be used. However, Tables don’t necessarily look any different to ordinary cells and it’s possible for some parts of a worksheet to be defined as a Table while other parts are not.
If you try to sort a range of cells that are partially within a table and partially outside a table, you’ll find that the Sort and Filter options are grayed-out and unusable, even though the cells might look completely ordinary!
The only way to tell for certain if a cell is contained within a Table is to click on it and look at the Ribbon.
If the cell is contained within a Table, the Table Tools > Design group will appear on the Ribbon.
Removing the Table should re-enable the sorting options (although it’s likely that whoever created the Table did so for a reason). You can remove the Table by clicking the Table Tools > Design > Convert to Range button on the Ribbon.
You can learn much more about Tables in our Expert Skills course.
The data may originate from an external data source
Some Excel data may originate from an external data source, such as a SQL Server database. This isn’t a problem in most cases, as Excel is able to apply sorting to most external data sources, but there are some that Excel may be unable to sort.
If the data is held in a data source that Excel cannot sort, you may need to copy it and paste it as Values before you can sort it.
Pasting values is explained in depth in our Essential Skills course.
We also explain external data sources in great depth in our Expert skills course.
These are the only up-to-date Excel books currently published and includes the new Dynamic Arrays features.
They are also the only books that will teach you absolutely every Excel skill including Power Pivot, OLAP and DAX.
25 Responses
August 2018 Excel 2016 – Found a group of cells outside the “Range” then clicked in a cell, the Design pop into Ribbon, Clicked on Design>Convert to Range> Popup Window “do you want to Convert the Table to a Normal range? YES / NO. similar as stated above.
Yes, this is exactly the process shown above, converting a Table into an ordinary Range.
OMG Thank you so much!! I just spent about 2 hours working on the spreadsheet and did not want to start over.. You are a life saver!!!
“Convert to Range” is also ghosted out, so this is not a fix. The worksheet is not grouped or protected. What else could it be?
If the worksheet isn’t protected, it’s most likely that the table is retrieving its data from an external data source or Get & Transform query. If this is the case, you may need to change the sorting options within the query itself or copy and paste the data elsewhere so that it is no longer connected to another data source.
This is just what I needed. Never realized that before but it makes sense.
Thank you!!!!!
Thank you!! Worked in Excel for years and this was driving me nuts!
I had this problem. Could not find the solution until I carefully scanned the cells and noticed in the last row a TINY black corner on the lower right corner of the first cell of that row. Hovering the mouse pointer over the corner made the cursor change from a pointer to a square outline. Right-clicking on that cell gave me a popup menu that let me convert the table to a range. Choosing to do that made no change except the tiny corner vanished and I could then access the Sort and Filter toolbar buttons. Beats me why the creator of this table did their table that way but I’m glad to have the sort/filter buttons available again! Writing this, I also discovered I could have right-clicked on any cell in that column to see “Convert to range” present in the right-click menu. Any other column, that option did not appear.
Hi Meg,
It looks like you were having the problem mentioned in the The data may be partially contained within a Table section above. It most likely happened because the workbook’s creator added or removed rows without realizing that they weren’t being included in their table.
As you observed, you can convert tables to ranges using the right-click menu, but the easiest way to tell if a cell is part of a table is usually to select the cell and see if the Table Tools > Design tab appears on the Ribbon.
I’m glad you were able to solve the problem; perhaps Microsoft will make it easier to spot Tables in a future version of Excel!
OH thank you so much! This fixed my issue!
Thank you for this explanation! That’s exactly what was going on with my document, and I had just spent quite a lot of time compiling a database so that I could sort it according to my preferences
AWESOME Help!
Thank you. Saved me from a headache
None of the above was working, then I noticed that there were 3 sheets in my spreadsheet. It should have only been one. The second and third sheets both had miscellaneous data from the original sheet scattered throughout. After deleted both sheets, I was able to sort the original. How could this have happened?
Hi Michael,
The only explanation I can think of is that you might have had the extra sheets selected without realizing it, giving you the problem described in the A worksheet group may be selected section above. After deleting the other sheets it was only possible to have one sheet selected so sorting and filtering became available again.
It’s also not unheard of for Excel workbooks to become corrupted; what you said about the extra sheets having scattered data from the first suggests this possibility. If you suspect that your workbook has become corrupt it can usually be solved by copying the data into a new workbook that has not been corrupted.
saver ! phew, i had no idea why not filtering.. thanks a lot. converting range worked. Big thanks.
I had no filter buttons on top of one of my table worksheets + Filer Button was greyed out.
Select Data/Click anywhere on table/click Filter Button -and all Filter Buttons appeared on top of the table.
Worked for me and I hope this may help others with this problem
Excel 2016
This has been my bane for such a long time. Your solution worked easy. Thanks Simon Smart!
Thank you!!! “The data may be partially contained within a Table” <– this. I don't even know how I created the embedded table, but this info was all I needed.
life saver. Thanks you very much
THANKS
Thank you very much.
Got this – thank you
You Rock! Solution #1 solved the problem. Thank you.