Answer:
There are perhaps something on the order of 1080 atoms in the observable universe, or at least that is a figure that seems to be tossed around a bit. A link can be found below.
We know that 1 mole of hydrogen is 1 gram, which has 6.022 x 10^23 atoms in it. We can easily approximate 1 kilogram (1000 grams) of any material to 1000 moles, since all atoms are based on the hydrogen model multiplied by X number of times corresponding to their atomic number.
So, for example, although 1 kg of Iron is not 1000 moles, as Hydrogen is, but about 20 moles, one mole of Iron has 26 protons (29 neutrons) and 26 electrons, and has about 26 times the mass of hydrogen. So 1 kg of Iron is about 6.022x10^23 * 20 = 1.2 x 10^24 ~ 10^24 atoms, this is not far from 10^26 hydrogen's atoms. The most common element and atom in the universe is hydrogen anyway. Therefore 1 kg of any material can reasonably be approximated to about 1000 moles, which is about 6.022 x 10^26 atoms, or about 10^26 atoms per kilogram of mass in the universe.
Earth has ~ 6 x 10^24 kg of mass. This is, 6 x 10^24 * 6 x 10^26 (number of atoms in 1 kg of substance) about 3.6 x 10^51 atoms or roughly 10^51 atoms. Now this might seem like very close to 10^80 atoms, but it is not. It would take approximately 10^30 Earths to reach that number, which is far more than our Galaxy has in mass.
Our Galaxy has 1.4 x 10^42 kg of mass, which is about 10^45 moles. Multiplying that times Avogado's number (6.022 x 10^23, or about 10^23) we get 10^68 atoms in the Milky Way. There are 125 billion galaxies in the observable universe, which is 1.25 x 10^11, which is approximately 10^11 galaxies. From that:
10^68 * 10^11 we get 10^79, or about 10^80 atoms (10^78 if we count atoms as heavy as Iron, above which the universe does not naturally make on any grand scale; it goes up to Uranium, which is about 5 moles/kg) in the observable universe, with about as many electrons (1 hydrogen atom as per our model has 1 proton and 1 electron).
----
A second way is to use the known length of the observable universe. The observable universe is about 93 billion light years. Taking the volume of the universe as a sphere: 4/3*pi*R^3, the volume of the universe would be:
(4/3)*3.141592*46.5^3 = ~ 4.2 x 10^23 cubic lightyears as the volume of the observable universe.
Knowing that the universe is about 0.0000000000000000000042 percent matter, multiplying 4.2 x 10^23 by that gives us ~ 1.77 cubic lightyears of matter.
1 lightyear is 10 trillion kilometers, which is 1 million trillion centimeters or 10^18 cm in 1 lightyear. 1 cubic lightyear would then be (10^18)*(10^18)*(10^18)=10^54 cubic centimeters in 1 cubic lightyear so about 1.77x10^54 cubic cm of matter in the universe. It's estimated that there are about 10^17 atoms in an average cubic centimeter, so 1.77x10^54 * 10^17 = 1.77 x 10^81 which is about 10^81 atoms in the universe