Tornadoes are caused when there are abnormally hot and humid conditions present in the lower atmosphere and cooler than usual conditions in the upper atmosphere. It is known as instability.
Along with instability, when there is enough wind shear present in the lower atmosphere, tornadoes are likely to form. Wind shear here means conditions when the wind keeps on changing direction and its speed increases with height. This combination of instability and wind shear exists usually before a low pressure area and a cold front. Some other weather conditions also help in the formation of tornadoes like when the dry air in the mid atmosphere is quickly cooled due to a thunderstorm. This escalates the downdrafts that cause tornadoes.