The main function of an ice bag is to reduce pain and swelling, and to numb the affected area. Ice bags are often used for recent injuries, such as sprains, bruises, and muscle pain.