# Removing chat from all pages

**URL:** <https://community.hubspot.com/t/removing-chat-from-all-pages/46034>\
**Category:** APIs & Integrations\
**Tags:** professional\
**Created:** [October 27, 2021, 2:09pm UTC](https://community.hubspot.com/t/removing-chat-from-all-pages/46034 "2021-10-27T14:09:40Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![mkranitz](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/mkranitz/32/27794_2.png) [@mkranitz](https://community.hubspot.com/u/mkranitz)\
**Post date:** [October 27, 2021, 2:09pm UTC](https://community.hubspot.com/t/removing-chat-from-all-pages/46034/1 "2021-10-27T14:09:40Z")

</div>

Hi gang,

I have learned how to remove the chat from some pages by using the following code:

.page-id-477 #hubspot-messages-iframe-container {display: none !important;}

I just create a new line in CSS for each page that I want to prevent the chatbot from showing up in.

Question is this: I don’t want the chat to show up at all. Is there a single line that I can enter into CSS that will do this? I currently have thirty entries and it’s kind of a drag to enter it each time.

I don’t want to do it from inside the HubSpot application - I want to control this with CSS as there are other sites using the chat feature.

Thanks in advance,

Mitch

---

<div class="post-metadata">

**Author:** ![dennisedson](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/dennisedson/32/28044_2.png) [@dennisedson](https://community.hubspot.com/u/dennisedson)\
**Post date:** [October 27, 2021, 3:20pm UTC](https://community.hubspot.com/t/removing-chat-from-all-pages/46034/2 "2021-10-27T15:20:27Z")

</div>

Hey @mkranitz

I would try to remove the **.page-id-477** from that css rule and only target the iframe ID.

---

<div class="post-metadata">

**Author:** ![mkranitz](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/mkranitz/32/27794_2.png) [@mkranitz](https://community.hubspot.com/u/mkranitz)\
**Post date:** [October 27, 2021, 3:36pm UTC](https://community.hubspot.com/t/removing-chat-from-all-pages/46034/3 "2021-10-27T15:36:22Z")

</div>

Thanks, Dennis! I should have mentioned that I did try to just add this line by itself to the Custom CSS options:

_#hubspot-messages-iframe-container {display: none !important;}_

But that didn’t work. It sounds like you’re suggesting something different, tho? I guess I need to learn what the iframe ID is? 🙂

Thanks so much,

Mitch

---

<div class="post-metadata">

**Author:** ![dennisedson](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/dennisedson/32/28044_2.png) [@dennisedson](https://community.hubspot.com/u/dennisedson)\
**Post date:** [October 27, 2021, 3:37pm UTC](https://community.hubspot.com/t/removing-chat-from-all-pages/46034/4 "2021-10-27T15:37:46Z")

</div>

@mkranitz ,

Would you be able to provide an example page with the chat on it?

---

<div class="post-metadata">

**Author:** ![mkranitz](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/mkranitz/32/27794_2.png) [@mkranitz](https://community.hubspot.com/u/mkranitz)\
**Post date:** [October 27, 2021, 5:20pm UTC](https://community.hubspot.com/t/removing-chat-from-all-pages/46034/5 "2021-10-27T17:20:31Z")

</div>

You bet - thanks for your help here!

[https://www.printpartner.biz/testtest](https://www.printpartner.biz/testtest)

That page has the popup.

---

<div class="post-metadata">

**Author:** ![dennisedson](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/dennisedson/32/28044_2.png) [@dennisedson](https://community.hubspot.com/u/dennisedson)\
**Post date:** [October 27, 2021, 5:52pm UTC](https://community.hubspot.com/t/removing-chat-from-all-pages/46034/6 "2021-10-27T17:52:36Z")

</div>

Give this a shot (adding some extra css just to go nuclear on it 😉)

```lia-code-sample
html #hubspot-messages-iframe-container {
 visibility: hidden;
 height: 0 !important;
 width: 0 !important;
 display: none !important;
}

```

---

<div class="post-metadata">

**Author:** ![mkranitz](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/mkranitz/32/27794_2.png) [@mkranitz](https://community.hubspot.com/u/mkranitz)\
**Post date:** [October 27, 2021, 6:02pm UTC](https://community.hubspot.com/t/removing-chat-from-all-pages/46034/7 "2021-10-27T18:02:46Z")

</div>

\*BOOM\* and there it is… Ladies and gentlemen, let’s give it up for Dennis! 👏👏👏

Thanks a bunch! I really appreciate your help with this 🙂
