Most children will experience an earache at some point, many of which are caused by ear infections. It is very reasonable to give your child ibuprofen or acetaminophen to help them feel better.Elevating the child’s head during sleep can also help to ease the pain. Unfortunately, neither a hot compress nor an ice pack is likely to help, because the source of the pain is way inside the ear, behind the drum.
Though most earaches are viral and clear up on their own, if it hasn’t gone away in two or three days, see your doctor. It could be a bacterial infection that would benefit from antibiotics.