Heat is a form of energy which is produced by the motion of the molecules of the body. It is a scalar quantity.
Temperature is that physical quantity which determines the thermal state of a body.
It determines the direction of flow of heat from one body to another body. Heat always flows from a body at higher temperature to a body at lower temperature. It is also a scalar quality.