I use the Facet module version 8.x-1.x-dev. I have a list of taxonomy terms with parents and childs.

The taxonomy term facet is an Entity reference field. I can't get the hierarchical structure working in the frontend.

2 Answers 2


I fixed it by re-added the field from admin/config/search/search-api/index/default_index/fields and take the ID from the index instead of name. Then in the Facet settings use Transform entity ID to label. Then the hierarchical structure from the taxonomy terms works!

  • Thanks @meez this helped me today
    – gillarf
    Oct 30, 2019 at 16:14

I was confronted with the same problem, Meez's comment helped me on my version (Drupal 8.9.9, Search API 1.17.0 and Facets 1.5.0), to have the option Transform entity ID to label on the facet, you must not go through the selection of an ID or Name attribute on the taxonomy field in admin/config/search/search-api/index/MYINDEX/fields, use it directly in the reference field of taxonomy (field_myfield_taxonomyreference). Everything else is fine, thank you.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.