Ore

Ore is a block type in Minecraft. Ores are primarily collected for crafting purposes, such as tools, armor, and more. Redstone ore is used as a type of "wiring", which can be used to create redstone circuits, compasses, clocks and more. Ore can also be combined to create a block of the material's type for iron, gold, diamond, and lapis lazuli. Blocks are hard to make, requiring nine pieces of each material to create.

Availability
In Minecraft Beta, the following is the distribution of ores according to the altitude. (Layers are number of blocks above the lowest layer of bedrock.) Since the beta 1.8 patch, the highest layers that Gold, Redstone, Diamond and Lapis can be found on are now two layers lower. The graph on the right shows the ore distribution in 1.1. The change to the 256-block worlds in the weekly releases before 1.2 did not affect world generation, as seen in this interactive chart.

** Based on the graph on the right.

Redstone has the same layer and line-size statistics as Diamond, but is generated 8 times per chunk as opposed to 1.

Ore is created by picking two points a certain distance apart, drawing a line between the points, and filling in any Stone blocks within a certain distance of the line with the ore being done in that round. Source (Section 3.11)

In chunks generated prior to Beta 1.6, ore also varies depending on the section of the map it is generated in, due to a bug (fixed in 1.6) in the spawning algorithm. In the quadrant south-west of the point (0,0), ore spawns approximately 50% more than in the quadrant north-east of the point (0,0). The quadrants north-west and south-east of the point (0,0) split the difference between the extremes. (See image below) Any chunks generated after Beta 1.6 do not show this disparity as the spawning algorithm has been fixed. The bug fix did not modify any already existing chunks.

History
In Minecraft Classic, you could only find exposed Coal, Gold and Iron in large amounts, from roughly 10 to 30 in a vein. Lapis Lazuli, Diamond and Redstone are not found because they were added in later updates. Since there is a lack of crafting system in classic, these can only be mined for fun and will not yield any useful materials.

As of 1.0.0 coal, Diamond, Redstone and Lapis Lazuli can now also drop as ore blocks with Silk Touch.

Trivia

 * Iron and Gold are the only ores that drop the actual ore block when mined without the Silk Touch Enchantment. All the other ores drop the usable item when mined.
 * Ore veins don't pass through chunk borders.