# Only allow hovertext for one axis

**URL:** <https://community.plotly.com/t/only-allow-hovertext-for-one-axis/4991>\
**Category:** Plotly R\
**Created:** [July 19, 2017, 3:07pm UTC](https://community.plotly.com/t/only-allow-hovertext-for-one-axis/4991 "2017-07-19T15:07:14Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![cicipoo](https://avatars.discourse-cdn.com/v4/letter/c/8baadc/32.png) [@cicipoo](https://community.plotly.com/u/cicipoo)\
**Post date:** [July 19, 2017, 3:07pm UTC](https://community.plotly.com/t/only-allow-hovertext-for-one-axis/4991/1 "2017-07-19T15:07:14Z")

</div>

The default behavior of the stacked bar chart appears to have hover text for each layer (which I want) as well as a hover text for the y-axis (which I don’t want). I only want the added annotation labels to show up on the left, without the same text in a hover tag appearing on top of it because it’s repetitive.

 ![](https://us1.discourse-cdn.com/flex024/uploads/plot/original/2X/b/b216b011a0b7bfd4503b0b08579a3813e1e3a6ef.png)

I tried getting rid of this by changing hovermode to x, y, and even closest, and it didn’t work. I also tried customizing the hovertext by adding the text argument to each trace. This didn’t work either. I thought maybe inside the yaxis object I could somehow pass the right info into the hoverformat argument, but I’m not seeing anything out there to give me any insight into that either. Someone please help.

---

<div class="post-metadata">

**Author:** ![bcd](https://avatars.discourse-cdn.com/v4/letter/b/ec9cab/32.png) [@bcd](https://community.plotly.com/u/bcd)\
**Post date:** [July 24, 2017, 2:57pm UTC](https://community.plotly.com/t/only-allow-hovertext-for-one-axis/4991/2 "2017-07-24T14:57:26Z")

</div>

Hi @cicipoo,

Have you tried using `hoverinfo = 'x'` [https://plot.ly/r/reference/#bar-hoverinfo](https://plot.ly/r/reference/#bar-hoverinfo)

---

<div class="post-metadata">

**Author:** ![cicipoo](https://avatars.discourse-cdn.com/v4/letter/c/8baadc/32.png) [@cicipoo](https://community.plotly.com/u/cicipoo)\
**Post date:** [July 24, 2017, 4:11pm UTC](https://community.plotly.com/t/only-allow-hovertext-for-one-axis/4991/3 "2017-07-24T16:11:42Z")

</div>

Yes I finally found that after posting this! I was using the wrong key words in my google searches 😊
