If the airline caused the missed connection (e.g., a delayed initial flight because of mechanical issues), the airline should rebook you on the next available flight. If the next departure flight is early the next morning, the airline should arrange for you to travel on a different carrier or arrange lodging and food.