No, hair cannot change color overnight.
Hair color is determined by the amount of melanin, a pigment, in each hair strand. Melanin production is a complex process that happens gradually over time, and it's not possible for it to change dramatically overnight.
While some temporary hair color products can change the appearance of hair quickly, these effects are only temporary and will fade over time.
If you're noticing a sudden change in your hair color, it's important to consult with a doctor or dermatologist to rule out any underlying medical conditions.