When you pay your fines, fees, and court costs, the money goes to the general fund of the state of Iowa. The state general fund distributes the monies to various state programs and agencies.
If you pay county sheriff jail fees (room and board fees) and fees for service of process performed by county law enforcement, those monies are distributed to the county.
If the violation involves a city ordinance or law and a judge orders payment of the fines and fees in a court order, these monies are distributed to the city.