It is perhaps the most famous bargain in all of mythology: the highest of the gods gives up an eye – willingly – for a single draught from a well. Odin's eye at Mimir's well is the story of what wisdom truly costs.
Beneath one of the three roots of the world-tree Yggdrasil lies Mimir's well. In it wisdom and understanding are hidden, and its keeper is Mimir – the wisest of all beings, who drinks from the well every morning and therefore knows more than anyone.
Odin, already lord of much, wants one thing more: to know. He comes to the well and asks for a draught. But Mimir demands a pledge, and no small one. Odin lays his eye in the well – and drinks. Ever since, the All-Father is one-eyed, and his eye rests forever in the water of wisdom. It is the same Odin who later hangs nine nights on the world-tree, sacrificing himself to win the runes: the god of knowledge pays for every insight with pain.
“I know where Othin's eye is hidden, / deep in the wide-famed well of Mimir; / mead from the pledge of Othin each morn / does Mimir drink: would you know yet more?”Völuspá 28–29, translation after Henry Adams Bellows (public domain)

Odin (Wotan) · Yggdrasil · Odin & the runes · The Norns at the well of Urd · The Norse pantheon.
Völuspá, Sigrdrífumál (Poetic Edda), English public domain: Henry Adams Bellows (1923). Snorri Sturluson, Gylfaginning, Ynglinga saga. Scholarship: Rudolf Simek, Dictionary of Northern Mythology; John Lindow, Norse Mythology.