We use "have to" to express obligation or necessity, such as children having to go to school or an employee having to take the bus to work. We can also use "have to" in questions to check if something is required. Additionally, using "don't have to" indicates there is no obligation or necessity, for example not having to work on Sundays or eat disliked foods.