Old English deah, deag "a color, hue, tinge," perhaps related to deagol "secret, hidden, dark, obscure," from Proto-Germanic *daugilaz (source also of Old Saxon dogol "secret," Old High German tougal "dark, hidden, secret").
Old English deagian "to dye," from the source of dye (n.). Spelling distinction between dye and die was not firm till 19c. "Johnson in his Dictionary, spelled them both die, while Addison, his near contemporary, spelled both dye" [Barnhart]. Related: dyed. For dyed in the wool (or grain) see wool (n.).