I keep seeing people ask for this. There are basically only two ways, neither of which are terribly easy unless you are willing to switch to a Lemmy alternative and then it can be a breeze with just a couple of button clicks.
First, note that on base Lemmy, it basically cannot be done, short of either spinning up your own instance or trying to do some advanced programming with spamblock filtering rules (that is likely to mess up the pages in some way). There is a related feature though - in User -> Settings -> Blocks -> scroll waaay down -> Block instance - except that unlike blocking a community or a user, this does not actually "block an instance", and instead merely (& misleadingly?) hides the communities on those instances. You will still see comments from those users, they can still downvote you, and ping your notifications, etc.
About the only thing the above approach offers beyond blocking those communities individually is that if ever new communities were to be made from those instances, they would be automatically hidden from your account. So not all that helpful imho.
(1) Use an App
I have heard that the Sync and Connect apps (+ maybe others?) offer this, as well as a plethora of other features. Note that Voyager does not work for this - it is the same type of blocking as mentioned above.
Check them out? If anyone wants to supplement this section, please submit a post to this community to help people who want to know! (and/or at least add it in the comments here)
(2) Lemmy Alternatives
What I do use is PieFed.social, which in addition to this feature also offers several other advancements not currently available in Lemmy such as Categories of Communities that makes finding additional content a breeze (though overall it is not as feature-rich or easy to use as base Lemmy; and yet its choice to use Python rather than Rust should help it to catch up extremely quickly, plus the admins are extraordinarily responsive to deal with any issues).
To block all users from a PieFed instance, the easiest way is to start from a user on that instance, click their account, then click More -> Block everyone from [instance_name]. Or you could go to a page with the instance name in the url, like https://piefed.social/instance/lemmy.ml and just click "Block everyone from [instance_name]" there.
PieFed also offers additional opportunities in-between blocking trolls vs. not doing so: accounts that meet certain criteria levels will have icons placed next to the account name, so that you can still see their content (rather than have it automatically removed) but not have to spend as much time parsing it as you would something that is more likely to have been offered in good faith.
Mbin likewise offers Categories, and cross-connection with Mastodon, and also user blocking too, though the process to do it is not nearly as easy. Overall I find that whole style confusing - e.g. "communities" become "magazines", downvotes become "reduces", upvotes are both "favorites" and also upvotes exist too that are entirely separate from that, plus you can see who offers favorites, but only from other Mbin/Kbin users and you cannot see the same for reduces. Though if you want Mastodon integration with Lemmy in one account, this is definitely the way to go (b/c it's the only one that does both:-). From @nictophilia@fedia.io:
It's not anywhere in the settings at all, lol. Like a hidden option. You have to go to the url
https://fedia.io/d/[instance_domain_name]
, like https://fedia.io/d/lemmy.ml. Then it will give you the ability to block, and that block will be reflected in your settings page.
Either of these alternatives should make you quite happy with the result!:-)
(3) Honorable mention: relying upon an instance admin
As a normal user, not an admin yourself, you cannot implement a custom block of users from any specified instance. However, you can either ask your current admins to implement such a block for you (would need the support of the entire community on that instance ofc), or move your account to one that has already done so?
The only instances I've ever heard of that block the big-3 (lemmygrad.ml, hexbear.net, and lemmy.ml) are:
- lemmy.cafe - has very welcoming messages, including a link guiding new users to this community!:-)
- Tesseract on dubvee.org - extremely impressive, if not for everyone, but definitely worth a look
- quokk.au
The caveat to all of these is that each is a single-admin instance. Those of us who recall the story of e.g. Kbin.social (or dmv.social or so many others) know how worrisome that can be in that it could vanish overnight with little to no warning. Then again, unlike Kbin.social, they seem quite healthy for now - definitely worth at least taking a look?
No matter what, thank you for sharing it then!:-)
Edit: for the lolz:
I am not sure how far we can take this line of reasoning but... ironically it is the same type of thing that we are talking about irl to "tankies on Lemmy" - like, does the presence of seeing one thing mean that you don't want to go to a place? Kinda yeah... if that gives the place a bad impression.
Though I think you hit the nail on the head earlier: this case is somewhat special since lemmy.cafe is so extremely tiny that even one user - ironically someone from another instance entirely (rottenwheel@lemmy.zip) - forms what looks at first glance to be over half the posts submitted to that instance.
It is also odd that there are only 5 users of that community, which nonetheless still has <50 total users (even the Pokemon community below it in traffic that has only 4 active users has >100 total members). Mind you I don't know how those numbers are calculated - does a "visit/view" count as activity, or what about a vote, or is it only a post or comment? Even this community !newtolemmy@lemmy.ca has had only 2 users last month, which I suspected may have both been me from 2 accounts, if a "view" were to count (if not, then it must have been someone else, or rather 2 other people).
But anyway, it's an extraordinarily large amount of posts for such a tiny community. Which... kudos to that person then, for keeping such a niche community alive on the Fediverse? We don't have to join it:-).
Btw here is an interesting recent exchange b/t that crypto poster and the instance admin: https://lemmy.cafe/post/8734571 - rottenwheel is definitely pushing for the site to leave the web and exist solely within the dark web, but the instance admin is having none of that (for one thing, that's simply not how Lemmy works).
So no, I don't believe that rottenwheel is a major force behind what is happening at lemmy.cafe - they are only posting a lot of content to a community that happens to be on it. But it is only one user, and one community, afaict.
But if people don't want to join it - either b/c of the crypto posts or b/c the instance itself is so tiny - then that's their prerogative. It's so great to have choices is it not?:-)
Hah thanks that was an almost funny exchange to read. LOL.