Tantrums are a common part of children's development, particularly during toddlerhood. Children have temper tantrums for three main reasons:
Because they are unable to cope with their feelings. These feelings can be anything from hunger, sickness, confusion, helplessness, frustration, anger or even terror. For a toddler with a somewhat limited vocabulary, being physically upset is the main way for him to express these feelings. For example, he may not be able to cope with not getting his own way. And your refusal to give in makes your child feel angry.
Because they have learned from past experience that a temper tantrum is rewarded. By getting what they wanted once as a result of a tantrum, they may have "temper tantrums" in order to force their will in a situation.
Because they want your attention. This can stem from feelings of being left out, ignored or lonely on the one hand, or from having gotten used to too much attention on the other.