A concise Architectury Loom template for building a shared mod with Fabric and NeoForge loaders.
This repository is a minimal multi-loader template built with Architectury Loom. It splits shared code into common/, keeps Fabric-specific code in fabric/, and keeps NeoForge-specific code in neoforge/.
common/— shared code, resources, and mixinsfabric/— Fabric entrypoints and metadataneoforge/— NeoForge entrypoints and metadatagradle.properties— shared versions and mod coordinates
- JDK 25
- Gradle Wrapper (
./gradleworgradlew.bat)
./gradlew buildUse your IDE's generated run configs, or Gradle tasks, to launch Fabric or NeoForge during development.
Note
This template currently targets Minecraft 26.1.1, Fabric Loader 0.18.6, Fabric API 0.145.3+26.1.1, and NeoForge 26.1.1.6-beta.
Before turning this into a real project, update at least:
mod_id,archives_name,maven_group, andmod_versioningradle.properties- package names under
common/src/main/java,fabric/src/main/java, andneoforge/src/main/java - metadata in
fabric/src/main/resources/fabric.mod.json - metadata in
neoforge/src/main/resources/META-INF/neoforge.mods.toml - resource file names such as
example_mod.mixins.jsonandexample_mod.accesswidener
If your mod does not need access wideners or access transformers, remove the wiring as a group instead of deleting only one file.
Delete these references:
common/build.gradle→loom { accessWidenerPath = file("src/main/resources/${mod_id}.accesswidener") }fabric/build.gradle→loom { accessWidenerPath = file("src/main/resources/${mod_id}.accesswidener") }neoforge/build.gradle→exclude "${mod_id}.accesswidener"common/src/main/resources/example_mod.accesswidenerfabric/src/main/resources/example_mod.accesswidener
Delete these references:
neoforge/src/main/resources/META-INF/neoforge.mods.toml→
[[accessTransformers]]
file="META-INF/accesstransformer.cfg"neoforge/src/main/resources/META-INF/accesstransformer.cfg
Tip
In this template, Fabric does not declare an access widener entry in fabric.mod.json, so you do not need to remove anything there.
- Shared initialization starts in
common/src/main/java/com/example/example_mod/ExampleMod.java - Fabric metadata lives in
fabric/src/main/resources/fabric.mod.json - NeoForge metadata lives in
neoforge/src/main/resources/META-INF/neoforge.mods.toml