
Swap Item
A Data Pack / Mod that adds a bunch of new commands that allows players to swap the item they are holding with the target slot of any mob!
About this Mod
Swap Item
A Data Pack / Mod that adds a bunch of new commands that allows players to swap the item they are holding with the target slot of a mob!
📥How to Install
Choose if you want to download the pure Data Pack version or the Mod version and follow the steps accordingly.
Data Pack
- 1) Download the Datapack
- 2) Chose the world you want to install the Data Pack in and navigate to its "datapacks" folder
- 3) Copy the downloaded Data Pack file (Swap Item) into this folder
- 4) Join the world and run
/reloadcommand
Mod
- 1) Download the Mod
- 2) Navigate to your
modsfolder (for the vanilla launcher the path is.minecraft/mods - 3) Put the downloaded .jar file (Swap Item) into this folder
- 4) Join the world and run
/reloadcommand
The Mod version of this Data Pack is compatibile with Fabric, Forge, Quilt and NeoForge
Note: support for NeoForge is available starting from version 1.2.2 of the pack
📖Features
This Data Pack introduces a bunch of new commands that allow you to swap two inventory slots between the player and an entity. Plus, as a bonus, you can now place any item in your head slot! Following the list of the commands and their effects.
Commands
| Command | Effect |
|---|---|
/trigger swapitem.entity.mainhand | Swap the item you are holding with the item in the mainhand slot of the entity you are looking at. | /trigger swapitem.entity.offhand | Swap the item you are holding with the item in the offhand slot of the entity you are looking at. |
/trigger swapitem.entity.head | Swap the item you are holding with the item in the head slot of the entity you are looking at. |
/trigger swapitem.entity.chest | Swap the item you are holding with the item in the chest slot of the entity you are looking at. |
/trigger swapitem.entity.legs | Swap the item you are holding with the item in the legs slot of the entity you are looking at. |
/trigger swapitem.entity.feet | Swap the item you are holding with the item in the feet slot of the entity you are looking at. |
/trigger swapitem.head | Puts the item you are holding in your head slot. |
YouTube Showcase
📤How to Uninstall
Data Pack
To uninstall the Data Pack version you can just run /function swap_item:uninstall command. When the uninstallation process is completed a confirmation message will be sent in the chat.
Mod
To uninstall the Mod version you need to run /function swap_item:uninstall command. Then you close the game and remove the jar file from your .minecraft/mods folder.
🔗External links
Available Versions
How to Install Swap Item on Your Server
Order Server
Order a Minecraft Java server with at least 3 GB RAM (4 GB recommended).
Set datapack Loader
In the panel under "Egg", select the datapack loader and matching Minecraft version (26.1.2).
Install Mod
Open the mod browser in the dashboard and search for "Swap Item". Click "Install" – done! Alternatively, upload the .jar via SFTP to the /mods folder.
Compatibility
Mod Loaders
Minecraft Versions
26.1.2, 26.1.1, 26.1 (+24 more)
Server-side
✓ RequiredRecommended RAM
4 GB(min. 3 GB)Frequently Asked Questions
Swap Item server crashes on startup – what to do?
Most common cause: wrong datapack version or insufficient RAM. Check the server log (latest.log) for "OutOfMemoryError" or "Mixin" errors. With Mado Hosting: ensure at least 3 GB RAM is allocated and the loader matches the mod version (26.1.2). You can switch loaders with one click in the panel.
Is Swap Item compatible with datapack and fabric and forge and neoforge and quilt?
Swap Item officially supports datapack, fabric, forge, neoforge, quilt for Minecraft 26.1.2, 26.1.1, 26.1. Note: Forge and Fabric mods are NOT cross-compatible – pick one loader and stick with it. The Mado dashboard automatically detects incompatible loader combinations.
Server lagging with Swap Item – how to optimize performance?
Recommended RAM: 4 GB (per 8 players). Use /spark profiler to check if Swap Item consumes the most tick time. Common fixes: reduce server view-distance to 8-10, install "performant" or "starlight" as supplementary mods on Forge. With Mado Hosting, your server runs on NVMe SSDs with dedicated CPU cores for minimal latency.
Similar Mods
Rent Modded Server
Install Swap Item with just one click on your server.