Day and night cycle

for a noob this is gibberish :joy:. but so for example when the moon comes up i have to change it to another material/parameter and use a timeline to make the transition more smooth?