How many organisms have ever lived on Earth?
it is impossible to know the exact number so here is my gross ballpark estimate of an upper bound -  i.e. the maximum number of organisms that could have lived on earth in the extreme best case scenario. in practice it is probably much less, but this is to get an idea of what kind of numbers we are dealing with.

The earth's volume is about 1.08321 * 10^12 cubic kilometers =  1.08321 * 10^21 cubic meters

The crust of the earth is 4-8km and the radius is about 6,353km giving around 1% of the total volume available for life.

Hence, the volume available, i.e. the volume of the crust is about 1.1 x 10^19 Meters.

An average-size bacterium such as the rod-shaped E-coli is about 2 micrometers long and 0.5 micrometers in diameter. Hence, the volume is roughly:

(2*10^-6)*(0.5*10^-6)*(0.5*10^-6) = 0.5*10^-18 meters

Hence, if the entire volume of the crust of the earth were entirely filled with e-coli bacteria, there would be:

(1.1 x 10^19 meters)/(0.5*10^-18 meters) = 1.3*10^36 bacteria on the earth.

Bacteria take time until they reproduce. If they reproduce faster than they grow, they will become reduced to zero size, so there must be a balance between growth and reproduction.

Under ideal conditions the E-coli bacterium would divide every twenty minutes. source

Let's say we have the maximum number of bacteria on earth dividing every twenty minutes. Somehow, they divide and then one dies so that the population is stable. (hypothetically)

The age of the earth is roughly 4.5 Billion years. Much of that time, it was not colonised, but just to give an upper bound let's assume it was colonized the whole time.

There are 525600 minutes in a year so this give

4.5 ^ 10^9 * 5.3* 10^5 = 2.385 * 10^15 minutes

Dividing by twenty minutes gives 1.1925 * 10^14 total reproductions.

Hence, the number of organisms that ever lived if the entire volume of the crust of the earth were entirely filled with e-coli bacteria reproducing at the maximum of every 20 minutes would be:

(1.2*10^14) *  1.3*10^36 bacteria = 1.56 * 10^50 bacteria 

This is an highly exaggerated gross estimate of the maximum number of organisms that ever lived in the extreme best case scenario. In practice it is probably 5-15 orders of magnitude less than this but we get an idea of the kind of numbers we are dealing with.

UPDATE: A more realistic number

The number of bacteria currently on earth is about 5*10^30 forming a biomass which exceeds that of all plants and animals. source. 

According to this source cited by the previous wikipedia article:


  Most of the earth’s prokaryotes (bacteria) occur in the open ocean, in soil, and
  in oceanic and terrestrial subsurfaces, where the numbers of cells are
  1.2 × 10^29, 2.6 × 10^29, 3.5 × 10^30, and 0.25–2.5 × 10^30, respectively. The numbers of heterotrophic prokaryotes in the upper
  200 m of the open ocean, the ocean below 200 m, and soil are
  consistent with average turnover times of 6–25 days, 0.8 yr, and 2.5
  yr, respectively. Although subject to a great deal of uncertainty, the
  estimate for the average turnover time of prokaryotes in the
  subsurface is on the order of 1–2 × 10^3 yr. The cellular production
  rate for all prokaryotes on earth is estimated at 1.7 × 10^30 cells/yr
  and is highest in the open ocean.


Hence we have about 1.7 x 10^30 New Cells/year

Multiply this by the estimated 3.5 Billion years (3.5*10^9) when the earth was colonized and we get


  5.95 * 10^39 Bacteria that ever lived. of course there were other organisms, but as above even the biomass of bacteria exceeds that of
  all plants and animals combined so their effect on this number is
  negligible. Likewise, the life conditions were surely not ideal at all
  times, so this number may be lower still.


For some perspective, the estimated number of atoms comprising all of planet earth is about 1.33 * 10^50 according to this source.

ESTIMATE OF NUMBER OF MAMMALS THAT EVER EXISTED

The upper bound for mammals is as follows.

The surface area of the land of the earth is 149 million square kilometers.

Let us consider if the entire land area of the earth was completely covered with mice.

A mouse is typically 10cm from nose to base of tail and about 5 cm wide=0.1*.05=0.005 square meters. So we get 200 mice per square meter.

Hence, if the entire land area of the earth were covered with mice the world population of mice would be:

149*10^12 square meters * 200 mice per square meter = 1.788 * 10^15 mice

Mice typically produce a litter of 6-8 young and a female can have 5-10 litters per year. source

Let's say we have this maximum population reproducing in a stable manner. i.e. for every new mouse, an old one dies.

Hence the total number of new mice per year would be:

1.8 * 10^15 * 8 young * 10 litters = 1.44*10^17 new mice per year.

Mammals appeared around 200 million years ago (source), so that makes

1.44*10^17 new mice per year * 200 million years

= 2.88 * 10^25 total mice.

In practice mice need space and resources and compete with other mammals which take up space and which reproduce less frequently. Likewise, deserts and polar regions are less inhabitable, and sometimes there are periods of droughts, and they don't always reproduce at the maximum rate etc. so the total number is probably about around 4-10 orders of magnitude less than this.

So it is probably something like 10^20 total mammals ever existed.