# Limiting @mentions to groups

**URL:** https://meta.discourse.org/t/limiting-mentions-to-groups/72465
**Category:** Support
**Created:** [October 20, 2017, 12:44pm UTC](https://meta.discourse.org/t/limiting-mentions-to-groups/72465 "2017-10-20T12:44:33Z")
**Posts on this page:** 14
**Page:** 1

<div class="post-metadata">

### Author: ![jackhadley91](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jackhadley91/32/119851_2.png) [@jackhadley91](https://meta.discourse.org/u/jackhadley91)
#### Post date: [October 20, 2017, 12:44pm UTC](https://meta.discourse.org/t/limiting-mentions-to-groups/72465/1 "2017-10-20T12:44:33Z")

</div>

We have a number of independent groups in our Discourse who shouldn’t have visibility of members in other groups.

I’ve created categories for each group to which only they have access/visibility, which works fine. However, when users post or reply to a topic they can still use @mentions to include any other user in the community.

Is it possible to block this so a user can only @mention other users in their group(s)?

Or turn off @mentions full stop?

---

<div class="post-metadata">

### Author: ![dax](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/dax/32/244677_2.png) [@dax](https://meta.discourse.org/u/dax)
#### Post date: [October 20, 2017, 12:53pm UTC](https://meta.discourse.org/t/limiting-mentions-to-groups/72465/2 "2017-10-20T12:53:48Z")

</div>

Did you have custom group mentions enabled only for “group members, admins and mods”?

All the automatic groups should be set to " nobody" or at least only “admins and mods”

---

<div class="post-metadata">

### Author: ![jackhadley91](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jackhadley91/32/119851_2.png) [@jackhadley91](https://meta.discourse.org/u/jackhadley91)
#### Post date: [October 20, 2017, 1:39pm UTC](https://meta.discourse.org/t/limiting-mentions-to-groups/72465/3 "2017-10-20T13:39:54Z")

</div>

![image](https://global.discourse-cdn.com/meta/original/3X/9/7/976c49eecec26f2c43c3f615f4393bbe0cadb270.png)

This is what groups are set as. Still seem to be able to @ people from other groups tho.

---

<div class="post-metadata">

### Author: ![dax](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/dax/32/244677_2.png) [@dax](https://meta.discourse.org/u/dax)
#### Post date: [October 20, 2017, 1:51pm UTC](https://meta.discourse.org/t/limiting-mentions-to-groups/72465/4 "2017-10-20T13:51:12Z")

</div>

Are you on the latest version of Discourse?

> [@Unable to mention groups](https://meta.discourse.org/t/unable-to-mention-groups/71746/8):
>
> Yea not sure about the previous value but the current settings for moderators here on meta are: Same for @Jean11 here on meta as well.

If your users are not enabled to mentions other custom groups they shouldn’t see the name of that groups in auto-complete popup if they try to write their name.

---

<div class="post-metadata">

### Author: ![jackhadley91](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jackhadley91/32/119851_2.png) [@jackhadley91](https://meta.discourse.org/u/jackhadley91)
#### Post date: [October 20, 2017, 1:56pm UTC](https://meta.discourse.org/t/limiting-mentions-to-groups/72465/5 "2017-10-20T13:56:43Z")

</div>

Yeah, I’m all up to date. Weird one…Might the settings take a while to filter through?

---

<div class="post-metadata">

### Author: ![dax](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/dax/32/244677_2.png) [@dax](https://meta.discourse.org/u/dax)
#### Post date: [October 20, 2017, 2:12pm UTC](https://meta.discourse.org/t/limiting-mentions-to-groups/72465/6 "2017-10-20T14:12:43Z")

</div>

As far as I know, changes of this kind are usually immediate, at most a few seconds. 🤔

---

<div class="post-metadata">

### Author: ![jackhadley91](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jackhadley91/32/119851_2.png) [@jackhadley91](https://meta.discourse.org/u/jackhadley91)
#### Post date: [October 20, 2017, 2:24pm UTC](https://meta.discourse.org/t/limiting-mentions-to-groups/72465/7 "2017-10-20T14:24:16Z")

</div>

It couldn’t be something to do with the WP site we are using discourse in combination with, could it?

---

<div class="post-metadata">

### Author: ![dax](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/dax/32/244677_2.png) [@dax](https://meta.discourse.org/u/dax)
#### Post date: [October 20, 2017, 2:33pm UTC](https://meta.discourse.org/t/limiting-mentions-to-groups/72465/8 "2017-10-20T14:33:10Z")

</div>

I do not use WP, nor SSO. Surely @simon can better answer about this point.

EDIT: since the problem seems to be only on your site (until proven otherwise), share the list of plugins you’ve installed. One of them could cause the problem.  
Have you tried to check if group mentions work badly even with [safe mode](https://meta.discourse.org/t/53504?silent=true) (`your-site/safe-mode`)?

---

<div class="post-metadata">

### Author: ![jackhadley91](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jackhadley91/32/119851_2.png) [@jackhadley91](https://meta.discourse.org/u/jackhadley91)
#### Post date: [October 20, 2017, 2:49pm UTC](https://meta.discourse.org/t/limiting-mentions-to-groups/72465/9 "2017-10-20T14:49:21Z")

</div>

I feel like our issue has less to with groups and more to do with individual users and so these setting aren’t what we need here.

So essentially, we have multiple groups

As an example:  
**GROUP 1:** USER A, USER B  
**GROUP 2:** USER C, USER D

Now when USER A brings up the text window and writes @ they are going to see USER C and D. This is an issue because USER A isn’t able to communicate with C or D, or know if of their existence. They can’t see any of the discussions GROUP 2, so they shouldn’t be able to see that group’s users when they bring in mentions.

Does this make sense?

Appreciate your help.

---

<div class="post-metadata">

### Author: ![dax](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/dax/32/244677_2.png) [@dax](https://meta.discourse.org/u/dax)
#### Post date: [October 20, 2017, 3:32pm UTC](https://meta.discourse.org/t/limiting-mentions-to-groups/72465/10 "2017-10-20T15:32:14Z")

</div>

Well, they are different things, those are mentions per user, not group.  
User A is able to “see” user D even if he does not know that user D belongs to another group, whether he has written post or open topic (and viceversa), until user A goes to the profile of user D.

What you want is a feature request.

In your case, would you like to disable the mentions per user and set it so that only members of the same group can “see” each other? Or at least completly disable all mentions?

Theoretically speaking:

- the first thing is to modify the site setting `enable user directory` so your user can’t see the page `/users` and the personal profile page of other users. I do not know if the setting is retroactive for those users who already subscribe to the forum (but it is a solvable problem) and enable `hide user profiles from public`

- then, ideally, you need to modify the site setting `max mentions per post` and set it to 0. Actually it doesn’t work, but you can ask the discourse team to improve this site setting, and when it is set to 0 the auto-complete don’t appears. If the team is interested and, secondarily, receiving requests from many other users they could also implement it.

- the last solution I can think of is that you write a plugin or pay some developer to write it to your place by making a request on the marketplace or buy a hosted enterprise plan from discourse (in this case they can do some implementation for your site, I think, but not 100% sure).

---

<div class="post-metadata">

### Author: ![jackhadley91](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jackhadley91/32/119851_2.png) [@jackhadley91](https://meta.discourse.org/u/jackhadley91)
#### Post date: [October 20, 2017, 4:57pm UTC](https://meta.discourse.org/t/limiting-mentions-to-groups/72465/11 "2017-10-20T16:57:34Z")

</div>

> [@Trash](#):
>
> In your case, would you like to disable the mentions per user and set it so that only members of the same group can “see” each other?

Ideally this is what we would like. I’ll look into your suggestions, and thanks for your help. From my perspective it makes a lot of sense as a feature as if there are ‘closed’ groups, then there should be an option for them to be un-discoverable.

Cheers!

---

<div class="post-metadata">

### Author: ![system](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/system/32/443519_2.png) [@system](https://meta.discourse.org/u/system)
#### Post date: [November 28, 2019, 1:10pm UTC](https://meta.discourse.org/t/limiting-mentions-to-groups/72465/12 "2019-11-28T13:10:08Z")

</div>



---

<div class="post-metadata">

### Author: ![system](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/system/32/443519_2.png) [@system](https://meta.discourse.org/u/system)
#### Post date: [September 2, 2023, 4:44am UTC](https://meta.discourse.org/t/limiting-mentions-to-groups/72465/13 "2023-09-02T04:44:08Z")

</div>



---

<div class="post-metadata">

### Author: ![JammyDodger](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jammydodger/32/254611_2.png) [@JammyDodger](https://meta.discourse.org/u/JammyDodger)
#### Post date: [September 2, 2023, 5:05am UTC](https://meta.discourse.org/t/limiting-mentions-to-groups/72465/14 "2023-09-02T05:05:37Z")

</div>


