Relay Starts with Arduino!

I face a problem with my projects if using relays.
Always when I start operating the Arduino the relay is on at the same time for a second almost and I don’t know why although there is no instruction for that. Here is my code for an egg incubator.

#include "dht.h"
#define dht_apin A0 // Analog Pin sensor is connected to A0
int heater = 5; //Pin 5 is connected to heater through Relay

dht DHT; //Calling the library for the dht sensor

void setup(){
 pinMode(dht_apin,INPUT);    //Analog pin is input
 pinMode(heater,OUTPUT); //Digital pin is output

 Serial.begin(9600); //Starting serial communication

void loop(){  

//Reading the temperature from the sensor
   int temp = DHT.temperature;

   Serial.print("temperature = ");
   Serial.println("C  ");
   delay(5000);//Wait 5 seconds before accessing sensor again.
if (temp < 37){ //Switch ON heater if temperature is low
else{digitalWrite(heater,HIGH);} //Switch off heater if it is hot enough

set the pin low (read throughly the doc)

put some delay as well at the very beginning...,
I assume you are connecting correctly the Relay...

Please edit you post to have code tags.

Also, devil is in de details. I bed you don't just use a relay but a relay module, don't you? If so, be sure to set it to the OFF state when you make the pin an output. Aka

digitalWrite(heater, HIGH);