{"id":1593,"date":"2021-02-14T13:02:01","date_gmt":"2021-02-14T13:02:01","guid":{"rendered":"https:\/\/meetanshi.com\/blog\/disable-filter-for-column-in-magento-2-grid\/"},"modified":"2025-05-22T11:03:15","modified_gmt":"2025-05-22T05:33:15","slug":"disable-filter-for-column-in-magento-2-grid","status":"publish","type":"post","link":"https:\/\/meetanshi.com\/blog\/disable-filter-for-column-in-magento-2-grid\/","title":{"rendered":"How to Disable Filter for Column in Magento 2 Grid"},"content":{"rendered":"\n<p class=\"wp-block-paragraph\">Magento 2 grids are the way to manage data by listing the items in a database table.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">The default&nbsp;<a href=\"https:\/\/meetanshi.com\/blog\/what-is-magento\/#:~:text=Meetanshi%20is%20a%20Magento%20development,E%2Dcommerce%20excellence%20each%20day.\" target=\"_blank\" rel=\"noreferrer noopener\">Magento 2<\/a>&nbsp;grid allows the admin to sort, filter and edit the data. Moreover, the admin can also use mass action, searching, and pagination to act on bulk data.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">While adding a&nbsp;<a href=\"https:\/\/meetanshi.com\/blog\/add-custom-column-in-magento-2-products-grid\/\" target=\"_blank\" rel=\"noreferrer noopener\">custom column in the grid<\/a>, it also displays in the filter option. However, not every column needs to be filtered. Implementing&nbsp;<a href=\"https:\/\/meetanshi.com\/blog\/implement-multiselect-filter-for-order-status-in-magento-2-order-grid\/\">implementing multiselect filter for order status in Magento 2<\/a>&nbsp;reminds us that keeping only the required columns in the filter area; otherwise, it will become messy if all the columns of your grid are shown in the filter option.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Thus you can&nbsp;<strong><em>disable the filter for column in the Magento 2 grid&nbsp;<\/em><\/strong>to remove any column of the grid from filter option.&nbsp;<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Here\u2019s the quick solution to do so:<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Method to Disable Filter for Column in Magento 2 Grid<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">You need to remove or comment the below line:<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">&lt;item name=\"filter\" xsi_type=\"string\">text&lt;\/item><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">That\u2019s it.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Feel free to share the solution with Magento Community via social media.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Thank You.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Related Posts:<\/strong><\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li><a href=\"https:\/\/meetanshi.com\/blog\/add-custom-column-in-order-grid-in-magento-2\/\" target=\"_blank\" rel=\"noreferrer noopener\">How to Add a Custom Column in Order Grid in Magento 2<\/a><\/li>\n\n\n\n<li><a href=\"https:\/\/meetanshi.com\/blog\/add-custom-column-in-order-grid-in-magento-2\/\" target=\"_blank\" rel=\"noreferrer noopener\">How to Create Admin Grid in Magento 2<\/a><\/li>\n<\/ul>\n","protected":false},"excerpt":{"rendered":"<p>Magento 2 grids are the way to manage data by listing the items in a database table. The default&nbsp;Magento 2&nbsp;grid allows the admin to sort,&#8230;<\/p>\n","protected":false},"author":13,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[34],"tags":[],"class_list":["post-1593","post","type-post","status-publish","format-standard","hentry","category-magento"],"acf":[],"_links":{"self":[{"href":"https:\/\/meetanshi.com\/blog\/wp-json\/wp\/v2\/posts\/1593","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/meetanshi.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/meetanshi.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/meetanshi.com\/blog\/wp-json\/wp\/v2\/users\/13"}],"replies":[{"embeddable":true,"href":"https:\/\/meetanshi.com\/blog\/wp-json\/wp\/v2\/comments?post=1593"}],"version-history":[{"count":2,"href":"https:\/\/meetanshi.com\/blog\/wp-json\/wp\/v2\/posts\/1593\/revisions"}],"predecessor-version":[{"id":14497,"href":"https:\/\/meetanshi.com\/blog\/wp-json\/wp\/v2\/posts\/1593\/revisions\/14497"}],"wp:attachment":[{"href":"https:\/\/meetanshi.com\/blog\/wp-json\/wp\/v2\/media?parent=1593"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/meetanshi.com\/blog\/wp-json\/wp\/v2\/categories?post=1593"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/meetanshi.com\/blog\/wp-json\/wp\/v2\/tags?post=1593"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}