Usually when this question is asked, the patient actually means bonded composite filling material. This material can be used either to restore cavities or can be applied to add to a patient's teeth for solely cosmetic reasons.
Bonding can remain in place for many, many years if the conditions in the mouth are right. I have many composite restorations in my patient's mouths for over twenty years without a significant deterioration. That being said, composite material reacts adversely to dental plaque that is not removed on a daily basis. It seems that the acid generated by the plaque makes the composite material become more porous. Some bonded fillings, especially in mouths that are not kept clean, can look almost 'water logged'. Composite material can imbibe some of moisture around them and this phenomenon seems most pronounced when plaque is left on their surface for long periods of time.
Bonded fillings are sensitive to the forces placed on them and can react poorly to excessive occlusal forces. Sometimes this can cause bonding to chip or crack after a period of time. If this happens the filling either needs to be repaired or replaced.
Some bonding can fail prematurely due to a poor bond to tooth structure. This can happen if there is excessive moisture contamination usually from saliva. Saliva is a terrific lubricant and most bonding agents do not work well when placed in the presence of saliva.
Also Occlusal forces should be taken into account when a dentist is finishing a filling. Care should be taken to have a patient check their teeth excursions to make sure that composite does not make overly hard contact with the opposing jaw's teeth.
To sum up, usually bonded fillings that are carefully done, and placed out of harms way (in terms of occlusal forces) can last a long time. I would expect in ideal conditions that their average life expectancy would be nine to fifteen years.