# How can I switch a tab from a button click?

**URL:** https://forum.builder.io/t/how-can-i-switch-a-tab-from-a-button-click/1966
**Category:** Visual Editor Help
**Created:** [March 28, 2022, 6:07pm UTC](https://forum.builder.io/t/how-can-i-switch-a-tab-from-a-button-click/1966 "2022-03-28T18:07:05Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![Canuckaholic](https://avatars.discourse-cdn.com/v4/letter/c/3e96dc/32.png) [@Canuckaholic](https://forum.builder.io/u/Canuckaholic)
#### Post date: [March 28, 2022, 6:07pm UTC](https://forum.builder.io/t/how-can-i-switch-a-tab-from-a-button-click/1966/1 "2022-03-28T18:07:05Z")

</div>

We are using the built-in Tabs component and would like to switch to one of the tabs when a user clicks a button in the content section of a different tab. I assume this can be done through data binding, but it’s not clear how.

---

<div class="post-metadata">

### Author: ![ancheetah](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.builder.io/ancheetah/32/751_2.png) [@ancheetah](https://forum.builder.io/u/ancheetah)
#### Post date: [March 28, 2022, 8:59pm UTC](https://forum.builder.io/t/how-can-i-switch-a-tab-from-a-button-click/1966/2 "2022-03-28T20:59:20Z")

</div>

Hey @Canuckaholic, this is not possible with the built-in Tab component because active tab state is inaccessible directly from the UI. Alternatively, you can create a custom component/template/symbol to achieve this behavior. As a starting point, you may find the open source code for the Tabs component useful:

> <https://github.com/BuilderIO/builder/blob/main/packages/widgets/src/components/Tabs.tsx>

---

<div class="post-metadata">

### Author: ![Canuckaholic](https://avatars.discourse-cdn.com/v4/letter/c/3e96dc/32.png) [@Canuckaholic](https://forum.builder.io/u/Canuckaholic)
#### Post date: [March 28, 2022, 10:07pm UTC](https://forum.builder.io/t/how-can-i-switch-a-tab-from-a-button-click/1966/3 "2022-03-28T22:07:30Z")

</div>

> [@ancheetah](#):
>
> Hey @Canuckaholic, this is not possible with the built-in Tab component

Ok thanks. Can I get this added to the feature requests? 🙂

---

<div class="post-metadata">

### Author: ![ancheetah](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.builder.io/ancheetah/32/751_2.png) [@ancheetah](https://forum.builder.io/u/ancheetah)
#### Post date: [March 28, 2022, 11:49pm UTC](https://forum.builder.io/t/how-can-i-switch-a-tab-from-a-button-click/1966/4 "2022-03-28T23:49:05Z")

</div>

Sure! Feel free to submit feature requests anytime on our ideas board where the community can upvote them: [https://ideas.builder.io/](https://ideas.builder.io/)
