How to Fix Recipe Loading Crash
A broken recipe is logged and skipped instead of crashing the game. How to find the file, fix it, and why the recipes folder stopped working in 1.21.
Quick Fix
Search latest.log for Couldn't parse data file, fix or remove the recipe it names, then run /reload or restart the server.
Error Message
Couldn't parse data file 'mypack:my_recipe' from 'mypack:recipe/my_recipe.json'How to Fix
Search latest.log for Couldn't parse data file. The line gives the recipe id and the file it came from.
Check the file with a JSON validator, then compare it with a vanilla recipe of the same type.
Move recipes from data/<namespace>/recipes to data/<namespace>/recipe for 1.21 and later.
Install the mod whose items the recipe uses, or delete the recipe.
Run /reload after fixing a data pack, or restart the server.
Common Causes
- The recipe file isn't valid JSON, for example because of a missing comma or bracket. The game skips that file and logs its name.
- The JSON is valid but doesn't fit the recipe format, such as a missing result or an unknown recipe type. The log line ends with what the game couldn't read.
- The recipe uses an item from a mod that isn't installed, so the item id doesn't exist.
- The data pack still uses the old recipes folder. Since 1.21 recipes have to be in data/<namespace>/recipe, and files in the old folder aren't loaded.
- Every ingredient of a recipe resolves to nothing, for example an empty tag. The game logs that the recipe can't be placed due to empty ingredients and will be ignored.
Diagnostic Steps
- Search latest.log for Couldn't parse data file.
- Open the file named in the message.
- Fix the JSON, the folder name or the missing item.
- Run /reload and check the log again.
FAQ
Where are custom recipes stored?
In a data pack under data/<namespace>/recipe since 1.21, and data/<namespace>/recipes before that. Mods keep theirs inside the mod jar in the same layout.
Does a broken recipe crash the game?
Not in vanilla. The file is logged and skipped, and all other recipes still load.
Why did my recipes stop working in 1.21?
The folder was renamed from recipes to recipe, so recipes left in the old folder aren't loaded.