Any Hat
by Ancar
Any Hat lets a player wear any item on the head slot through a datapack and a trigger command, with no separate hat mod needed.
What it does
Any Hat is a datapack that adds a hat trigger command, so a player can wear an item from the hand or inventory in the head slot. The datapack is placed in the datapacks folder of a world directory and works with vanilla hats and stylish accessories alike. It runs on the server, so server owners install it once and players join without anything extra. Clients may add it for the same behavior, but it is not required.
The mod targets 1.16 – 26.3 across Fabric, Forge, NeoForge and Quilt, and a data pack build is also published. Snapshot builds have files too. Any Hat is released under the GNU General Public License v3.0 only and is open source; its source code and issue tracker are public. The most recent file is 3.0.5+mod for 26.3, published 2026-09-15.
Key features
Wear any item as a hat
A trigger command places the held item on the head slot, so items beyond the usual helmets can be worn.
Vanilla hat support
The datapack works with vanilla hats and transforms accessories into stylish hats without changing their items.
Simple setup
Copy the datapack into the datapacks folder of the world directory and the command becomes available.
Duplication protection
The datapack is built to be dupe safe, so worn items cannot be copied through the hat trigger.
Gallery
Compatibility
Latest build for each game version and loader.
26.x5 of 5 versions with builds
1.21.x12 of 12 versions with builds
1.20.x7 of 7 versions with builds
1.19.x5 of 5 versions with builds
1.18.x3 of 3 versions with builds
1.17.x2 of 2 versions with builds
1.16.x6 of 6 versions with builds
This mod also publishes snapshot builds. Snapshots are not shown in the matrix.
How it compares
Hats On is server-side, licensed under the GNU General Public License v3.0 or later, and published for 1.21 – 1.21.5 on four loaders. /hat is a datapack for 1.21 – 26.2 under the MIT License. Useful Hats runs on both client and server across 1.14.4 – 26.3 under the MIT License.
| Mod | Loaders | Game versions | Environment | Updated |
|---|---|---|---|---|
| Any Hat | Fabric, Forge, NeoForge and Quilt | 1.16 – 26.3 | Server required, client optional | 2026-09-15 |
| Hats On | Fabric, Forge, NeoForge and Quilt | 1.21 – 1.21.5 | Server required, client optional | 2025-04-05 |
| /hat | Fabric, Forge, NeoForge and Quilt | 1.21 – 26.2 | Server required, client optional | 2026-06-17 |
| Useful Hats | Fabric, Forge, NeoForge and Quilt | 1.14.4 – 26.3 | Client and server | 2026-10-02 |
Questions
Does Any Hat need to be installed on the client?
Which loaders does Any Hat support?
Where does the datapack go on a server?
In the catalog
Any Hat is one of 17,631 Equipment mods on ModsFinder, and one of 8,894 Equipment mods for Fabric. 8,071 mods support Minecraft 26.3.
More from Ancar
Similar mods
What the author says
Transform your accessories into stylish hats! Hats by Ancar, is a datapack which allows you to wear any item as a hat. It is by far the best hat datapack for the following reasons.
Official listing
- Modrinth page
- modrinth.com/mod/any-hat
- Owner
- Ancar
- Published
- 2024-08-18
- Updated on Modrinth
- 2026-09-15
- Facts verified
- 2026-10-15
