var maxHeight = 0; $(".row-flex-grid .filter-item").each(function() { if ($(this).outerHeight() > maxHeight) { maxHeight = $(this).outerHeight(); } }).height(maxHeight);