# How to add custom attributes to search bar

**URL:** <https://community.hivepress.io/t/how-to-add-custom-attributes-to-search-bar/4000>\
**Category:** HivePress\
**Created:** [January 19, 2023, 3:32pm UTC](https://community.hivepress.io/t/how-to-add-custom-attributes-to-search-bar/4000 "2023-01-19T15:32:24Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![yrnelvis](https://community.hivepress.io/letter_avatar_proxy/v4/letter/y/3ab097/32.png) [@yrnelvis](https://community.hivepress.io/u/yrnelvis)\
**Post date:** [January 19, 2023, 3:32pm UTC](https://community.hivepress.io/t/how-to-add-custom-attributes-to-search-bar/4000/1 "2023-01-19T15:32:25Z")

</div>

How can I add custom attribute to the search bar? Current I can search only by categories, keywords and locations but I would like to add a custom attribute.

---

<div class="post-metadata">

**Author:** ![andrii](https://community.hivepress.io/user_avatar/community.hivepress.io/andrii/32/2951_2.png) [@andrii](https://community.hivepress.io/u/andrii)\
**Post date:** [January 20, 2023, 1:45pm UTC](https://community.hivepress.io/t/how-to-add-custom-attributes-to-search-bar/4000/3 "2023-01-20T13:45:27Z")

</div>

Hi,

If you have the Bookings extension and features like **multiple bookings per time period** and **time slots** are disabled, you can add **Dates** to the search bar in **HivePress \> Settings \> Listings \> Default fields**.  
Also, if **multiple places per booking** and **multiple bookings per time period** are enabled, you can add the **Guests** field instead of the **Dates** field.

You can add a custom attribute and mark it as **Searchable** , then it will show up at the main search bar.

---

<div class="post-metadata">

**Author:** ![yrnelvis](https://community.hivepress.io/letter_avatar_proxy/v4/letter/y/3ab097/32.png) [@yrnelvis](https://community.hivepress.io/u/yrnelvis)\
**Post date:** [January 20, 2023, 3:03pm UTC](https://community.hivepress.io/t/how-to-add-custom-attributes-to-search-bar/4000/4 "2023-01-20T15:03:37Z")

</div>

Is it possible to display the custom attribute in the filter form ONLY when a specific category is searched?

---

<div class="post-metadata">

**Author:** ![ihor](https://community.hivepress.io/user_avatar/community.hivepress.io/ihor/32/5_2.png) [@ihor](https://community.hivepress.io/u/ihor)\
**Post date:** [January 22, 2023, 12:11pm UTC](https://community.hivepress.io/t/how-to-add-custom-attributes-to-search-bar/4000/5 "2023-01-22T12:11:51Z")

</div>

Yes, please edit this attribute and assign it to a specific category, then it’ll appear for listings within this category only.

---

<div class="post-metadata">

**Author:** ![system](https://community.hivepress.io/user_avatar/community.hivepress.io/system/32/13990_2.png) [@system](https://community.hivepress.io/u/system)\
**Post date:** [February 21, 2023, 12:12pm UTC](https://community.hivepress.io/t/how-to-add-custom-attributes-to-search-bar/4000/6 "2023-02-21T12:12:30Z")

</div>

Closed on February 21, 2023, 12:12pm UTC

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.
