{{lowercase title}}
{{about|the directory used by Bedrock Edition|the directory used by ''Java Edition''|.minecraft}}
{{distinguish|Mojang.com}}
{{exclusive|bedrock|education}}
{{File|directory|'''com.mojang'''|inline=1}} is a directory used internally by ''Minecraft'' Bedrock Edition. It contains worlds, [[JSON]] data, and other files necessary for the game to run.
== Location ==
{{/path}}
=== Android quirks ===
On Android, there are two distinct {{File|directory|'''com.mojang'''|inline=1}} directories - internal and external. If the ''File Storage Location'' option is set to ''Application'', all data is stored in the internal directory. If it's set to ''External'', some data (such as worlds) is stored in the external directory, but the internal directory is still used for other data.
The external directory can be viewed and edited by users, though it might require workarounds in newer Android versions. The internal directory cannot be viewed or edited without root access. It's not possible to migrate worlds and other data between those directories without root access.
The user ID is usually 0
, but differs if the user is a secondary user. /storage/emulated/''user ID''
is often presented as ''Internal storage'' or similar by file managers, or when you access the device via MTP (connected to a Linux, macOS or Windows computer).
== Directory structure ==
.mc
suffix instead of .jpeg
.
** {{File|file|ud''id''.dat}} (there may be more than one)
** {{File|directory|world_templates}}{{info needed|What is in this directory?}}
** {{File|file|xal}}{{verify|Exists in PE 1.16.0+?}}{{info needed|Is it the account data for XBL?}}{{verify|Is this a regular file and not a directory?}}
/storage/emulated//games/com.mojang
.
|The file hierarchy of com.mojang is as follows:
com.mojang/../games/com.mojang/minecraftWorlds
. {{File|directory|minecraftWorlds|inline=1}} does not have any additional files.}}
|{{HistoryLine||v0.5.0|Added {{File|file|level.dat_old|inline=1}} under {{File|directory|''world name''|inline=1}}, which is a backup of {{File|file|level.dat|inline=1}}.}}
|{{HistoryLine||v0.7.0|Added the {{File|directory|minecraftpe|inline=1}} directory under {{File|directory|com.mojang|inline=1}}.
|{{File|directory|minecraftpe|inline=1}} contains two files: {{File|file|clientId.txt|inline=1}} and {{File|file|[[options.txt]]|inline=1}}.
|Added the {{File|directory|players|inline=1}} directory under {{File|directory|''world name''|inline=1}}.}}
|{{HistoryLine||v0.7.3|Added the {{File|directory|_LevelCache|inline=1}} directory under {{File|directory|minecraftWorlds|inline=1}}, whose usage is not currently known.}}
|{{HistoryLine||v0.9.0|dev=build 1|
{{Collapse|title=Due to the switch to the [[Bedrock Edition level format/History#LevelDB based format|LevelDB level format]], the file hierarchy of com.mojang is now as follows, with temporary files from worlds using the previous level format being struck through:|content=
MANIFEST-######
.
***** {{File|file|LOCK}}: An empty file.
***** {{File|file|MANIFEST-######}}
**** {{File|file|chunks.dat}}
**** {{File|file|entities.dat}}
**** {{File|file|importedchunks.dat}}: Lets the game know which chunks have been converted to the new level format.
**** {{File|file|level.dat}}
level.dat_old
is now created if the player goes to a given world's edit menu and changes any settings in it. Doing this also deletes the world's level.dat
file, though it is created again upon world reentry.}}
|{{HistoryLine||v0.13.0|dev=build 1|The snooper
directory has been moved from com.mojang/minecraftpe/snooper
to com.mojang/snooper
. The old snooper
directory still remains, but is no longer updated.}}
|{{HistoryLine||v0.14.2|snooper
is no longer created nor updated by the game.}}
|{{HistoryLine||v0.15.0|dev=build 1|Added r.txt
file under minecraftpe
. The content of this file is Vanilla
.
|LOG
and LOG.old
files are no longer generated by the game.}}
|{{HistoryLine|||dev=build 2|Added r2.txt
file under minecraftpe
. The content of this file is Minecraft
.
|r.txt
is no longer created by the game.
|level.dat_old
is once again created by the game whenever the player exits a world.}}
|{{HistoryLine|||dev=release|Added resource_packs.txt
file under minecraftpe
. The content of this file is Minecraft
.
|r2.txt
is no longer created by the game.}}
|{{HistoryLine||v0.16.0|dev=build 1|resource_packs.txt
is now an empty file by default.
|resource_packs.txt
files are now created for each individual world under
.}}
|{{HistoryLine|||dev=build 4|Added global_resource_packs.txt
file under minecraftpe
. This file is empty by default.}}
|{{HistoryLine|||dev=build 5|Added two directories under com.mojang
: behavior_packs
and resource_packs
. Both are empty by default.
|Added Perf_Log.csv
file under com.mojang
.
|Replaced global_resource_packs.txt
with global_resource_packs.json
.
|Added two directories under
: behavior_packs
and resource_packs
. Both are empty by default.
|Added two files under
: world_behavior_packs.json
and world_resource_packs.json
.
|resource_packs.txt
files are no longer generated by the game.
|
{{Collapse|title=The file hierarchy of com.mojang
is now as follows:|content=
/data/user//com.mojang.minecraftpe/games/com.mojang
(internal) and /storage/emulated//Android/data/com.mojang.minecraftpe/files/games/com.mojang
(external).}}
|{{HistoryLine||1.20.0|dev=Preview 1.20.0.22|The files {{File|file|.nomedia|inline=1}} and {{File|file|ud''id''.dat|inline=1}}, and directories {{File|directory|logs|inline=1}}, {{File|directory|minecraftpe|inline=1}} and {{File|directory|xal|inline=1}} in the external {{File|directory|com.mojang|inline=1}} directory on Android are no longer used.{{bug|MCPE-176675||Settings lost because some files and folders are no longer generated within external storage}}}}
|{{HistoryLine||1.20.10|dev=Preview 1.20.10.20|The directory {{File|directory|logs|inline=1}} in the external {{File|directory|com.mojang|inline=1}} directory on Android is once again used.}}
|{{HistoryLine||1.20.70|dev=Preview 1.20.70.20|The directory {{File|directory|minecraftpe|inline=1}}, and the files {{File|file|.nomedia|inline=1}} and {{File|file|ud''id''.dat|inline=1}} in the external {{File|directory|com.mojang|inline=1}} directory on Android are once again used.}}
}}
== Notes ==
{{Notelist}}
== References ==
{{Reflist}}
== Navigation ==
{{Navbox Bedrock Edition}}
[[Category:Development]]
[[es:Com.mojang]]
[[fr:Com.mojang]]
[[lzh:Com.mojang]]
[[pt:Com.mojang]]
[[zh:Com.mojang]]