It comes from the word ἔκλειψις (ékleipsis), which means "abandonment," "failure," or "disappearance." This is quite fitting, as an eclipse is the temporary disappearance of a celestial body, either by the shadow of another body (like the moon during a solar eclipse) or by passing into the shadow of another body (like the earth during a lunar eclipse).
The word "ékleipsis" itself is formed from the verb ἐκλείπω (ekleípō), meaning "to leave out," "to fail," or "to cease."
Therefore, the word "eclipse" reflects the ancient Greek understanding of the phenomenon: a temporary disappearance of a celestial body.