Guides
/
Building Search UI
/
UI & UX patterns
Jan. 20, 2022
Sorting Refinements in InstantSearch Android
On this page
Sorting Refinements
With InstantSearch, we make it easy for you to customize the order of your refinement lists. You can sort them in two ways, alphabetically or by occurrence (by refinement count), in ascending or descending order.
Example
Using our RefinementList widget, you can specify how it is sorted with the sortBy
property.
For example in the RefinementList
’s code sample, sortBy="['isRefined', 'count']"
will display the refined facets before the non-refined ones, and will then sort them by decreasing count.
Did you find this page helpful?