Server-side item banning for NeoForge modpacks. No KubeJS. No scripts. Just hold the item and run a command.
Modpack balance is hard. Every update, every new mod, every gameplay decision can introduce items that break progression, trivialise challenges, or just don't belong. The usual answer is KubeJS — a powerful tool, but one that requires scripting knowledge, careful reload management, and a non-trivial setup just to remove a single item.
Contraband does one thing and does it well: it lets server operators ban items from existence with a single command, no scripts required.
Banned items are removed through multiple enforcement layers to ensure nothing slips through:
/give, creative mode, trades, container interactions, or any other means are removed automatically.The inventory sweep doesn't stop at the top level. Banned items are hunted down inside:
IItemHandler capability is covered. This includes Sophisticated Backpacks, Iron Backpacks, Traveler's Backpack, and most others.Banned items are automatically hidden from recipe viewer mods. Contraband maintains a datapack (datapacks/contraband_jei_hide.zip) that sets the c:hidden_from_recipe_viewers item tag for all currently banned items. This tag is respected by JEI, REI, and EMI out of the box.
The datapack is regenerated silently every time an item is banned, unbanned, or the list is reloaded. Run /reload once after any changes to push the update into JEI/REI/EMI.
Operators can manage the ban list entirely in-game without ever touching a file:
| Command | Description | Permission |
|---|---|---|
/contraband banhand |
Ban the item you are currently holding | OP |
/contraband ban hand |
Same as above | OP |
/contraband ban <id> |
Ban by item ID — full tab-complete from all registered items | OP |
/contraband unbanhand |
Unban the item you are currently holding | OP |
/contraband unban hand |
Same as above | OP |
/contraband unban <id> |
Unban by item ID — tab-complete shows only currently banned items | OP |
/contraband list [page] |
Paginated list of all banned items | Any player |
/contraband check <id> |
Check whether a specific item is currently banned | Any player |
/contraband reload |
Reload the ban list from disk without restarting | OP |
/contraband export |
Manually regenerate the JEI hide datapack | OP |
Most commands require operator permission level 2 (configurable). list and check are intentionally open to all players — useful for modpack documentation and player transparency.
Contraband uses a standard NeoForge server config (serverconfig/contraband-server.toml), generated automatically on first launch.
[features]
# Delete banned items when a player picks them up from the ground.
deleteOnPickup = true
# Scan and clean player inventories on login.
deleteOnLogin = true
# Void the crafting result for banned items.
removeRecipes = true
# Strip banned items from all loot tables.
modifyLoot = true
[permissions]
# Require operator permission level 2 to use /contraband commands.
requireOp = true
# Send a chat message to players when a banned item is removed from their inventory.
notifyPlayer = true
The ban list itself lives in config/contraband_banlist.json — a plain sorted JSON array of item IDs, easy to diff, version control, and copy between packs.
Contraband is a server-side mod. It does not need to be installed on the client. Players connecting with a vanilla client or a different mod list will be subject to all enforcement rules the moment they join.
IItemHandler capability contract for container itemsmodifyLoot toggleKubeJS is excellent for complex scripting. Contraband is for the operator who wants to quickly remove a problematic item — right now, in-game, without writing a script, without a reload cycle, and without reading documentation. It's the right tool when the job is simply: this item should not exist on this server.
Contraband is open source. Issues and contributions welcome.