Light

From the Minecraft Beta 1.7.3 Wiki

Light is a level from 0 to 15 held by every block space.

Light level

Every space stores two values from 0 to 15:

  • Sky light, which comes from the sky.
  • Block light, which comes from blocks that give off light.

A space's light level is the higher of its block light and its sky light minus the sky's darkness.

Sky light

A space open to the sky has sky light 15, however far down it is. A space is open to the sky when nothing above it is a full opaque block or one of the blocks listed below. Any other space takes the brightest sky light among its six neighbours, minus the light lost in its own block.

The Nether has no sky light.

Block light

The blocks below give off light. The space a source stands in has that much block light. Any other space takes the brightest block light among its six neighbours, less the light lost in its own block.

IconNameLight
LavaLava15
FireFire15
GlowstoneGlowstone15
Jack 'o' LanternJack 'o' Lantern15
Locked chestLocked chest15
TorchTorch14
FurnaceFurnace13
PortalPortal11
Redstone OreRedstone Ore9
Redstone RepeaterRedstone Repeater9
Redstone TorchRedstone Torch7
Brown MushroomBrown Mushroom1

A furnace gives off light only while it burns, redstone ore only while it glows, a redstone torch only while it is on and a repeater only while it is powered.

What stops light

Light loses 1 for each block it passes through. A full, opaque block stops it. Every other block loses 1, as air does, and leaves the space below it open to the sky, except these:

IconNameLight lost per block
LeavesLeaves1
CobwebCobweb1
WaterWater3
IceIce3
LavaLavaAll
Double Stone SlabDouble Stone SlabAll
Stone SlabStone SlabAll
Wooden StairsWooden StairsAll
FarmlandFarmlandAll
Stone StairsStone StairsAll

Slabs, stairs and farmland stop light although they do not fill their space. The game reads the light at one of them as the brightest of the spaces above and beside it.

Day and night

The sky's darkness is subtracted from sky light when a light level is read. It is 0 by day and 11 at night, so a space open to the sky reads 15 by day and 4 at night:

Time of day (ticks) Sky light read
0 to 12,040 15
12,040 to 13,670 falls from 15 to 4
13,670 to 22,330 4
22,330 to 23,960 rises from 4 to 15

Rain darkens the daytime sky to 12, and a thunderstorm to 10. Neither darkens the night.

The game counts it as day while the sky reads 12 or brighter.

The stored sky light never changes with the time of day. Some checks read a space's light without subtracting darkness, and see a space open to the sky as 15 at midnight.

A day is 24,000 ticks, kept by the world clock.

What light affects

What Needs Reads
Hostile mob spawning two random tests stored sky light, then light level
Animal spawning above 8 light level, ignoring night
Crops and saplings growing 9 or more, in the space above light level
Grass spreading 9 or more above the grass, 4 or more above the dirt light level
Grass dying below 4, under water, ice, lava, an opaque block, a slab, stairs or farmland light level
Flowers, roses, tall grass, dead bushes, crops and saplings staying put 8 or more, or open to the sky light level, ignoring night
Mushrooms spreading and staying put 12 or less light level, ignoring night
Ice melting above 8 block light alone
Snow layers melting above 11 block light alone
Zombies, skeletons and pig zombies catching fire 12 or more, open to the sky, by day: a chance each tick, from 1 in 120 at 12 to 1 in 25 at 15 light level
Spiders seeking a player 11 or less light level
Hostile mobs except slimes and ghasts ageing towards despawning 12 or more, at three times the rate light level
Hostile mobs except slimes, ghasts and giants wandering prefer darker spaces light level
Giants wandering prefer brighter spaces light level
Animals wandering prefer grass, then brighter spaces light level