Rabbits are not considered nocturnal, but rather crepuscular animals. This means they are most active during the hours of sunrise and sunset.
Rabbits have become crepuscular animals in time. They prefer to come out during the hours of sunrise and sunset because these are the times when the light is dim.
In the wild, rabbits are most often hunted by animals such as foxes and owls. Foxes are diurnal animals, meaning they hunt during the day and owls are nocturnal. Rabbits are safe when they come out when the light is dim enough for these and other predators to not be able to see well due to the reduction of light.