Wiki ArticleLocal entity data availablePages using simple calculatorJava Edition specific informationPages with sound tablesPages with Java sound tables

Experience

Experience (EXP or XP for short) can be gained from defeating mobs or performing many kinds of other actions. Experience has no direct effect on the player character, but it can be used to enhance their equipment through enchanting, or by using an anvil to repair, rename, or combine enchantments on equipment. Most sources of experience are produced in the form of experience orbs. , experience gained affects the player's score on the death screen. Experience orbs also recover durability on items with Mending that are being worn or are in-hand.

Local game data

Experience Orb

Java 1.21.4
Typemob
Stack-
Height0.5
Sections6
Canonical IDmob:experience_orb
Minecraft IDminecraft:experience_orb
Wiki sourcecached

Experience (EXP or XP for short) can be gained from defeating mobs or performing many kinds of other actions. Experience has no direct effect on the player character, but it can be used to enhance their equipment through enchanting, or by using an anvil to repair, rename, or combine enchantments on equipment. Most sources of experience are produced in the form of experience orbs. , experience gained affects the player's score on the death screen. Experience orbs also recover durability on items with Mending that are being worn or are in-hand.

Sources

Experience can be gained from several different sources. Most sources drop experience in the form of orbs, which can be claimed by any player, while a few methods directly award the player experience upon completing the action. From killing most mobs, which drop experience orbs along with any other items. However, mobs will only drop experience points if they are killed by a player, and not, for example, falling off a cliff. A mob does not drop experience orbs unless it dies within five seconds (100 game ticks) of an attack registered as a player hit (including tamed wolves, player thrown fireballs, and TNT). This allows gaining experience orbs from, say, knocking a monster off a cliff, lighting a mob on fire, etc. (fetching the orbs might be another question). The player can also try to "claim" a burning monster by hitting or shooting it once—even if the blow doesn't kill it, if the mob dies within 5 seconds, it drops experience orbs. Mobs killed by TNT activated by a player using flint and steel or a flaming arrow drop XP as usual; however, mobs killed by TNT that was activated by fire, redstone, or an explosion that wasn't player activated does not drop any experience orbs. Mobs drop a random number of experience orbs, which can have different values. However, the total value always remains within the values given below, regardless of difficulty setting. Hostile mobs give more experience orbs than passive ones. Baby animals, bats, golems, and villagers give no experience orbs at all. The ender dragon gives experience orbs totaling 12,000 XP the first time a player kills it—12 times more than anything else in the game—and 500 XP in subsequent defeats. Some hostile mobs spawn with weapons, or can spawn with weapons and/or armor. These mobs give an extra 1–3 points (randomly) per piece of equipment that they spawned with if the piece is not dropped. Equipment picked up after spawning doesn't count. Mining a monster spawner block gives 15–43 points of experience orbs. Mining a naturally-generated creaking heart drops 20–24 experience. While they do not drop experience orbs normally, baby mobs as well as mobs killed by non-player means are accepted by the sculk catalyst, allowing for experience orbs to be obtained in a more indirect way. From mining any ore that drops a resource, rather than raw metals or themselves. The experience orbs are produced along with the mineral item(s). If a Silk Touch pickaxe is used to mine the ore block, the experience is not dropped, but the block can later be placed and mined normally to release the mineral and the experience. The ore still produces orbs if destroyed by an explosion, whether or not it was caused by player activated TNT. From mining sculk, sculk sensors, sculk shriekers, and sculk catalysts. If a Silk Touch tool is used to mine it, the experience is not dropped, but it can later be placed and mined normally to release the experience. From smelting any of various items. Smelting any ore yields some experience, but normally only nether gold ore and ancient debris are worthwhile. For all other ores, mining them is better. Moderate amounts are gained by smelting/cooking other materials: food, clay balls or blocks, cactus, wood logs, sand, or cobblestone, cactus giving the most. The smelted material must be taken from the furnace through its GUI window. If the player uses a hopper to unload the furnace, it is possible to retrieve all experience produced by the furnace by smelting an extra item and taking it from the GUI. Breaking the furnace drops all stored experience as collectable experience orbs. From breeding animals. Orbs are produced where the parents are, along with the baby animal. Breaking eggs does not give experience. From fishing. The experience is awarded directly upon reeling in the fish, even if the fish itself is not picked up. From trading with villagers. A bottle o' enchanting releases orbs when broken. From the command. From disenchanting items in a grindstone. From completing a challenge advancement. Gathering experience points increases the player's experience level by gradually filling a bar on the bottom of the screen until a new level is achieved when the bar is full. When the player dies, they drop experience orbs worth 7 * current level experience points, up to a maximum of 100 points (enough to reach approximately 7.5 levels), and all of the other experience vanishes. If the gamerule keepInventory is set to true, the experience is kept even if the player dies.

Experience orbs

Most experience sources drop experience in the form of experience orbs, which can then be claimed by any player. Experience orbs fade between green and yellow colors and float or glide toward the player up to a distance of 7.25 blocks (calculated from the center of player's feet and the center of the experience orb), speeding up as they get nearer to the player. Experience orbs pulled toward a player are slowed by cobwebs. Experience orbs can also be pulled around or away from the player by running water currents. When collected, experience orbs make a bell-like sound for a split second. Unlike items, experience points are picked up gradually: no matter how many orbs are in the range of the player, they are added to the player's experience one at a time (10 orbs/second). In extreme cases, this can result in the player being followed by a swarm of orbs for many seconds. If an experience orb isn't collected within 5 minutes of its appearance, it despawns.

Orb sizes

Experience orbs vary in value. The general worth of an orb is reflected by its size, with eleven possible sizes corresponding to specific values. The three smallest sizes are the most commonly encountered, as the majority of experience dropped by mobs and blocks is less than ten. Dense experience orbs with values 17 or higher have orange "eyes" or "cores", and are less frequently encountered, most commonly from defeating the ender dragon, wither and other players, disenchanting objects on a grindstone, breaking spawners, and collecting items from high-traffic furnaces. For performance improvement, experience orbs of the same value can merge into a single entity, but they do not create a higher value orb.

Dropping orbs

Naturally spawned orbs always have an integer value of 1–11, 17, 37, 73, 149, 307, 617, 1237, or 2477. Fishing, breeding, and trading drop a single orb with a random value in the appropriate range. Breaking blocks, killing mobs and players, smelting items, and bottles o' enchanting calculate their total experience amount and then split it into the base values of orbs by size (1, 3, 7, 17, 37, 73, 149, 307, 617, 1237, and 2477). Higher values are chosen first, so, for example, a total value of 1000 would be dropped as orbs with values 617, 307, 73, and 3. While the first ender dragon in a world drops 12,000 experience, it is dropped in 10 waves of 1000 and one of 2000, so no orbs of value 2477 are dropped. Such orbs can exist in the world via furnaces that have had a lot of traffic. Like items, experience orbs float when on water. Experience orbs can be destroyed by fire, lava, explosions, and cacti, and can trigger pressure plates and tripwires. , although mob drops spawn the instant the final blow is dealt to the mob, experience orbs do not appear until the mob entity disappears and the smoke appears. , experience orbs appear in the same spatial and temporal location as loot when an entity is killed.

Negative orbs

Orbs with negative values can be created using the command, either using values below 0 or above 32767 due to 16-bit integer overflow. They use the smallest texture of experience orb. Negative orbs behave differently from positive orbs, namely that they do not deduct experience when collected by the player. They deduct durability from a tool enchanted with Mending, provided the tool is already damaged prior to collection of the orbs.

Experience amounts by source

For example, when smelting 1 coal ore and removing the coal, the value is 0.1, so this grants a 10% chance of getting 1 experience point. Or, when smelting 64 cobblestone and removing all 64 stone, the value is 0.1 * 64 = 6.4, so this grants 6 experience points, plus a 40% chance of getting 1 additional experience point. The following mobs and similar entities do not drop experience when killed:

Local Data Properties

displayNameExperience Orb
nameexperience_orb
id47
categoryUNKNOWN
typeother
width0.5
height0.5