The best way is to teach by example. If you have acted wrongly in front of your child or yelled at him/her; tell him/her that you are sorry. Explain them the reason for your over reaction and anger and teach them how to control anger. If the child has never encountered an apology, it will be difficult for him/her to do it himself. You also need to show him/her that it doesn’t matter that he/she is older or younger, when he/she is wrong it is wise to admit mistake and say sorry. Do not leave this lesson for later. The earlier you start, there will be better results. Toddlers learn quickly and observe a lot so teach them at younger age.
If your child makes a mistake, let the situation calm before shouting at him/her. Children also have feelings and can get angry. If you order an apology, he/she will only do it under pressure instead of feeling sorry from the heart. Talk to your child and ask him/her if he/she thinks he/she was at fault. Explain to him/her what he/she did wrong and how it hurt the other person. Make him/her see the other person’s point of view and position. Your child needs to learn about taking care of the feelings of others, this way he/she will feel sorry if he/she hurt someone and will be ready to apologize.
If your child is ready to apologize to someone for the first time, ask him/her to do it in front of you first. Kids have the habit of saying sorry and adding an excuse for why they did what they did. Explain to them that simple I’m sorry is enough and they do not need to justify themselves as to why they were right. This takes away the essence of the apology. Also make them see how light they feel after apologizing.