Nuclear Reaction Within Stars
Stars convert hydrogen into helium, and mass is converted into energy. The larger the star, the more quickly this reaction occurs.
Lifespan of a Star
Because large stars convert mass into energy more quickly than small stars, they age faster. Massive stars may generally be assumed to be young, as they are still quickly burning through their fuel, whereas the reaction has slowed in smaller, older stars.
Star Clusters
It is possible to determine the age of a star within a cluster because it may be assumed that the entire cluster was formed at the same time. The age of stars within a cluster is determined by calculating the mass of the largest star, how much hydrogen it initially must have had, and how fast it is burning through that fuel. The color and brightness of a star helps to determine at what point in its lifespan the cluster is.
Individual Stars
Without a cluster to which to compare an individual star, it is usually impossible to determine its age. General assumptions may be made that large stars are "young," but anything more specific cannot be accurately determined.