Screenshot 1 of 3. Two villagers stand near a wooden fence and a house, one holding a dark sword-like item, in Villager Guards.
What Villager Guards works with.
| Platform | Java Edition |
|---|---|
| Loaders | Fabric, Forge, NeoForge, Quilt |
| Minecraft versions | 1.21, 1.21.11, 26.1.2, 26.2, 26.3 |
| Environment | Client, Server |
Villager Guards adds archer and swordsman guards to villages, for Fabric, Forge, NeoForge and Quilt. It runs on the world's host, and joining players need nothing extra. Anyone searching for a villager guards data pack is in the right place, because the same project ships as loader mods and as a plain datapack.
Loaders and versions
- Fabric, Forge, NeoForge and Quilt: Minecraft 1.21 to 26.3. The newest build needs no dependencies; some builds for 1.21.4 require Utils.
What the guards do
Existing villagers are converted to guards at random. There are two types, archers and swordsmen, and both can pick up weapons, armour and totems. You can also make one by hand. Drop a bow at a fletcher villager to get an archer, or drop an iron sword at a weaponsmith villager to get a swordsman.
Two ways to install
- 1.Mod route: pick the file made for your loader (Fabric, Forge, NeoForge or Quilt), put it in the mods folder, and launch with that loader's profile. The guide to installing mods on Java covers the steps.
- 2.Datapack route: use the plain datapack file instead of a loader file.
Commands and tags
The project is a datapack underneath, so control comes from commands and entity tags rather than a settings screen.
- `/function villager_guards:config` opens the configuration.
- `/tag add villager_guards.natural_spawn.procced` on a villager stops it from being converted into a guard.
- `/tag add villager_guards.target.bypass` on an entity stops guards from attacking it.
- A summon function under `villager_guards:guard/` places guards directly.
Questions about Villager Guards.
4 questions
How do I stop a villager from becoming a guard?
Add the tag villager_guards.natural_spawn.procced to that villager with the /tag add command. Villagers carrying it are skipped by the random conversion, so they keep their profession and trades. It works per villager, so tag each one you want to protect before the conversion reaches it.
How do I make a villager guard myself?
Drop a bow at a fletcher villager to turn it into an archer, or drop an iron sword at a weaponsmith villager to turn it into a swordsman. You can also place guards directly with the summon function that lives under villager_guards:guard/.
What happens if I remove Villager Guards from a world?
Villagers that were already converted do not return to normal. The guards stay in the world but no longer function, and they do not get their old trades back. Because of this, think before adding it to a world you care about.
Is Villager Guards a mod or a datapack?
Both. It is a datapack at its core, published as plain datapack files and as mod files for Fabric, Forge, NeoForge and Quilt. Use a mod file if you already run a loader, or the datapack file if you want no loader at all.








