It depends on the type of infection. Swimming with a middle ear infection while receiving treatment for it is not a problem, but if your child has swimmer’s ear, it is best  to avoid swimming until symptoms are resolved. Your provider can help you determine appropriate parameters for water play.  If avoidance is not an option, be sure to prevent water from getting into the ear with ear plugs or a swim cap.