// crash guide
Minecraft server crash: Mixin apply failed
Mods change Minecraft's code with small patches called mixins. This crash means one of those patches couldn't be applied, usually because a mod is the wrong version or two mods are changing the same code. The log names the patch and the game class it was patching, which points you to the mod.
What the error looks like
Start with logs/latest.log. Most mixin crashes happen at startup and may not leave a crash report, but if there's a new file in crash-reports/, check it too. Forge and NeoForge also write logs/debug.log with more detail. On a Pelican panel, the live console shows the same lines and the file manager opens both folders.
Forge and NeoForge
[main/ERROR] [mixin/]: Mixin apply failed examplemod.mixins.json:MinecraftServerMixin -> net.minecraft.server.MinecraftServer: org.spongepowered.asm.mixin.injection.throwables.InvalidInjectionException Critical injection failure: @Inject annotation on onTick could not find any targets matching 'tickServer' in net.minecraft.server.MinecraftServer. Using refmap examplemod.refmap.json [PREINJECT Applicator Phase -> ...]
A few lines later comes the stack trace that stops the server:
org.spongepowered.asm.mixin.transformer.throwables.MixinTransformerError: An unexpected critical error was encountered
Caused by: org.spongepowered.asm.mixin.throwables.MixinApplyError: Mixin [examplemod.mixins.json:MinecraftServerMixin] from phase [DEFAULT] in config [examplemod.mixins.json] FAILED during APPLY
Caused by: org.spongepowered.asm.mixin.injection.throwables.InvalidInjectionException: Critical injection failure: @Inject annotation on onTick could not find any targets matching 'tickServer' ...
Fabric and Quilt
Fabric's build of Mixin puts the mod ID right in the message:
[main/ERROR]: Mixin apply for mod examplemod failed examplemod.mixins.json:ServerWorldMixin from mod examplemod -> net.minecraft.class_3218: org.spongepowered.asm.mixin.injection.throwables.InvalidInjectionException Critical injection failure: @Inject annotation on onTick could not find any targets matching ...
java.lang.RuntimeException: Mixin transformation of net.minecraft.class_3218 failed
Caused by: org.spongepowered.asm.mixin.transformer.throwables.MixinTransformerError: An unexpected critical error was encountered
Caused by: org.spongepowered.asm.mixin.throwables.MixinApplyError: Mixin [examplemod.mixins.json:ServerWorldMixin from mod examplemod] from phase [DEFAULT] in config [examplemod.mixins.json] FAILED during APPLY
Names like class_3218 and method_12345 on Fabric (1.21.11 and older), or m_12345_ and func_12345_a on older Forge, are the game's normal runtime names. They don't mean anything is corrupted. From 26.1 on, Minecraft isn't obfuscated, so the names are readable on every loader.
Other forms of the same crash
| Search the log for | What it usually means |
|---|---|
could not find any targets matching | The method the mod wants to patch isn't there. Wrong version, or another mod rewrote it. |
failed injection check, (0/1) succeeded | The method was found, but not the exact spot inside it. Another mod may have changed that code, or the version is wrong. |
Invalid descriptor on | The target method exists, but its arguments changed. Usually a version mismatch. |
InvalidMixinException: @Shadow ... was not located in the target class | A field or method the mod relies on is gone. Usually a version mismatch. |
@Redirect conflict. Skipping | Two mods tried to replace the same call. This is a warning that names both mixin configs. The skipped patch often fails next with “failed injection check”. |
Not every mixin line is the crash. Warnings like Reference map '...' could not be read, does not specify "minVersion" property and @Mixin target ... was not found show up on healthy servers too. A Mixin apply failed line marked WARN, with the server still starting, was an optional patch. It probably isn't what stopped your server, even if a log scanner flags it.
What it means
Mods don't ship a modified copy of Minecraft. They ship patches instead. Each mod lists them in a config file inside its jar, like examplemod.mixins.json. A patch says: in this class, find this method (or one call inside it), and add or replace code there. Mixin applies it the moment that class loads.
The patch fails when that code isn't where it expects. Two usual reasons:
- Version mismatch. The mod was built for a different Minecraft version, where that method had another name or other arguments. Addons built for a different version of the mod they extend fail the same way.
- Two mods, one spot. Another mod already changed that code, so the patch has nothing to attach to. Performance mods turn up here often, simply because they rewrite so much of the game.
The mod named in the error owns the patch that failed. It may be the victim, not the cause.
Common in these packs: Fabric packs, where mods change the game mostly through mixins, such as Create: Astral and Prominence II, especially after you add or update mods yourself. Forge and NeoForge packs get them too, often from performance mods.
How to fix it
- Stop the server and take a backup. On a Pelican panel, that's the Backups tab. You may end up removing mods, and removing a mod that adds blocks or items takes them out of your world.
- Read the three names. In
examplemod.mixins.json:MinecraftServerMixin -> net.minecraft.server.MinecraftServeryou get the config (which mod), the patch, and the target class (what it was patching).- Fabric and Quilt:
for mod examplemodgives you the mod ID directly. - Forge and NeoForge: the config name usually contains the mod ID. If it doesn't, open the likely jars as zip files and look for that file, usually at the top level.
- If the target class is from another mod rather than the game (not
net.minecraftorcom.mojang), the patch was probably written for a different version of that mod.
- Fabric and Quilt:
- Undo your last change. If the server worked before you added or updated a mod, move that jar from
mods/to amods-disabled/folder in the server root, or put the old version back. If it broke after a whole pack update, roll the update back. - Check that every version matches. Each mod must be built for your exact Minecraft version and loader. A 1.20.1 mod doesn't belong on a 1.20.4 server, even if it seems to load. Addons often need a specific version of the mod they extend. For a modpack, use the server pack for the same pack version your players have.
- Update the usual suspects. Update the named mod, the mod that owns the target class, your loader (newest build for your Minecraft version, unless your modpack needs a specific one), and mods that patch a lot of code, like Lithium, FerriteCore and ModernFix. Sodium, Embeddium and Rubidium are client-side rendering mods. If they're on the server, take them out (see client-only mods).
- Find the other mod. If every version is right and it still fails, a second mod is patching the same code.
- Search
latest.log(anddebug.log) foralready redirected by. That warning names both mixin configs, which usually point to the two mods. - Add
-Dmixin.debug.verbose=trueto the Java flags, before-jar(or before the@args file that newer Forge and NeoForge start with). On a Pelican panel, the start command is on the Startup tab, if your server lets you edit it. Mixin then logs a line for every patch it applies, with the class it patches. Search for your target class to see which other configs patch it. Remove the flag afterwards, because the log gets large. - Still stuck? Move half the mods to
mods-disabled/, test, and halve again. Keep the libraries the rest need; a missing dependency error names them. Setlevel-name=mixintestinserver.propertiesso you test on a throwaway world, then set it back.
- Search
- Fix the pair. Check both mods' issue trackers. Conflicts are often already reported and fixed in a newer version. Lithium (
config/lithium.properties) and ModernFix (config/modernfix-mixins.properties) let you turn off single patch groups by setting them tofalse; their docs list the names. Otherwise, drop one of the two mods.
Loader notes
- Forge and NeoForge: Forge mods usually list their configs under
MixinConfigsinMETA-INF/MANIFEST.MF. NeoForge mods may use[[mixins]]inMETA-INF/neoforge.mods.toml. That tells you which jar owns a config. Running Fabric mods through Sinytra Connector? Remove the Fabric mod first and test. - Fabric and Quilt: configs are listed under
"mixins"infabric.mod.json, or"mixin"inquilt.mod.json. Update Fabric API (or Quilted Fabric API, if your Quilt server uses it) along with the mod.
How to check it's fixed
- Start the server. It should reach
Done (12.345s)! For help, type "help"with no new file incrash-reports/. - Search
logs/latest.logforMixin apply,FAILED during APPLYandCritical injection failure. If none of them show up as ERROR lines, the required patches applied. - Join and play for a few minutes. Mixin patches a class only when it first loads, and some classes only load once a player joins or new chunks generate.
- A different error now is progress: the loader got further.
Paste your log into the free crash log analyzer. It spots mixin failures in Forge, NeoForge, Fabric and Quilt logs and names the mod when the log does.
Related crash guides
Modded hosting is relaunching.
DSN hosts modded Minecraft only, with 5 on-demand backups for testing mod changes, nightly off-site backups, and a live console and file manager for working through a conflict. We're moving DSN Servers to new hardware, and ordering is closed until then. Join the launch list and we'll email you when servers open.