Cells have an internal "clock." This clock tells them how many times they can divide before they must exit the loop by committing cell suicide. This kind of cell death is called apoptosis (pronounced "apohtosis").
Apoptosis is a natural cell process which affects many things. For example, when a human fetus is developing, many vestigial (ancient but no longer necessary) features begin to develop, but mysteriously stop dividing at some point during development. This is another form of apoptosis in action. External factors can also induce a cell to undergo apoptosis. One example is found in our immune system. Certain cells produce factors that are designed to induce apoptosis in the foreign cells they encounter. Other apoptosis inducers include glucocorticoids and radiation. There are many others. Cancer cells grow out of control. They do not know when to stop dividing. They are resistant to the normal factors which induce apoptosis in healthy cells. If you have a normal liver cell and a malignant (cancerous) liver cell, and you grow them in a dish in the lab, you'd find that the normal liver cell would die after a few divisions. The cancer cell, on the other hand, would not die. That's because it has a defective internal clock, or has become resistant to apoptosis inducing factors. Such cells that are grown for routine use in the lab are called "transformed," because they have been artificially made resistant to apoptosis.