In coastal areas during the day, land gets heated faster than water. So there is low pressure on land and vice versa in the sea. So the wind flows from sea to land. This is known as sea breeze.
During night, the land has quickly radiated all the heat and the sea still possesses some heat. So sea has low pressure and land has high pressure. Hence, the wind direction changes an becomes from land to sea. This is called land breeze.