The stars are distant suns. So, to understand the stars, you must first understand our own sun.
The sun is essentially a very large, very hot ball of gas, mostly hydrogen. At its surface, called the sun's photosphere, the temperature averages a little under 6000 degrees Kelvin (about 10 000 degrees Fahrenheit). The deeper you go into the sun, the hotter it gets and the greater the pressure becomes. If you were to go deep enough within the sun's interior, it would be so hot (several million degrees), and the pressure so high, that the hydrogen would undergo thermonuclear fusion and become helium. Nuclear fusion is the same process that powers a hydrogen bomb; it also provides all the energy the sun now emits. The region around the center of the sun, in which these nuclear fusion reactions take place, is called the core.
A nuclear fusion reaction produces gamma rays, not visible light. Why, then, aren't we being blasted with lethal doses of gamma rays from the sun? Because the sun's core is thousands upon thousands of kilometers below its surface. The gamma rays have to work their way up to the surface through an opaque haze of hot, compressed hydrogen and helium ions, losing a little energy with each particle they bounce into. It takes the energy generated in our sun's core over a million years to reach its photosphere. By the time it does, it has cooled from harsh gamma rays to a smooth distribution of visible light.
The sun glows a certain yellowish color based on its surface temperature. If you were to heat up a piece of metal in a blast furnace, it would eventually get so hot that it would glow a dull red (like an electric stove on medium-high power). Continue heating it and it would turn a brighter red, then orange, then yellow (the sun's color), and finally white. To glow "white hot" in this fashion, it would have to be heated to over 10 000 degrees Kelvin (about 18 000 degrees Farenheit). At that high a temperature, even the sturdiest of metals would be an ionized vapor (called a "plasma"); but it would still glow white with heat if this vapor were thick enough to be opaque. If you continued to heat this plasma to 15 000 degrees Kelvin, 20 000 degrees Kelvin, or even hotter, it would eventually appear to glow blue rather than pure white. Physicists refer to this heat-glow as blackbody radiation; and it's this blackbody radiation by which, like a blacksmith's hot horseshoes or the filament of a lightbulb, the sun glows.
With few exceptions, stars are simply suns that come in a variety of sizes. Stars smaller than our sun have lower pressures and temperatures in their interior, which means they have smaller cores, which in turn means they can't produce as much energy as the sun does and are therefore cooler and redder. Most stars are much smaller than our sun; you would need to gather ten thousand of the smallest "red dwarfs" to produce as much light as our sun does. By contrast, stars larger than our sun have higher pressures and temperatures in their interior, which means they have larger cores and can produce more energy than the sun does More importantly, though, if a star has at least twice the sun's mass and has at least a little carbon in its core, it can take advantage of a more efficient nuclear fusion reaction that will produce energy a lot faster. The combination of a larger core and this more-efficient nuclear reaction make the star's photosphere a lot brighter and a lot hotter. A few of the stars are "blue giants," much bigger and hotter than our sun, continuously shining with up to a million times its brightness.
But because a star heats itself by fusing its own supply of hydrogen into helium, it cannot shine forever. Eventually it will run low on hydrogen fuel and will have trouble supporting its outer layers under their own weight. Our sun has about five thousand million years to go before this happens, having already radiated away nearly the first five thousand million years of its fuel supply. Ironically, the lower a star's mass is, the longer its fuel will last, since low mass stars produce energy much more slowly than high mass stars do. (The article on Stellar Evolution gives a more thorough treatment of how stars are born, live, and die.)
During its core-hydrogen-fusion lifetime (called the time the star is on the main sequence), most stars produce energy at a nearly constant rate, bathing nearby space in steady visible and invisible light. What's more, the material that coalesced to form the star itself can also congeal into smaller non-luminous bodies orbiting around the star, called planets. Planets that have formed at just the right distance from a star and have enough heavy elements (like carbon, nitrogen, and oxygen — anything heavier than helium) can settle down in the star's constant brightness and harbor life as we know it. Even planets that aren't the right distance from a star, though, can be rich repositories of water, ammonia, simple hydrocarbons, and minerals — assuming the material that formed the star (and therefore its planets) was rich enough in heavy elements. Some stars are heavy-element poor; these stars belong to the galactic Thick Disk and Halo populations that formed long ago, when the galaxy was so young that its interstellar medium had not yet been enriched with heavy elements.
Several factors contribute to whether a given star system is capable of harboring its own complex life like the Earth does. Many of these factors, such as exactly how old the star is or whether the star system has any planets in the comfort zone, cannot be accurately measured with the equipment and techniques currently available to astronomers. Many other factors that are measurable, however, can allow modern astronomers to make an educated guess.
For a star to have a chance of supporting complex life as we know it:
Throughout this reference, the ambiguous terms "billion," "trillion," etc. have been avoided, due to their meaning different things to a U.S. and a British reader. (What an American calls a billion, a Brit calls a milliard; what a Brit calls a billion, a Yankee calls a trillion.)
Furthermore, no commas have been used to separate groups of three digits in a large number; this reference follows the international convention of using a space instead (e.g. thirty-five thousand is written 35 000 instead of 35,000). This is due to the practice in several foreign languages of using a comma as a decimal point (!) rather than a three-digit-group separator.