Nanak was born in 1469 at Talwandi, west of Lahore, into a Hindu family of the Khatri merchant caste, and worked as an accountant for a Muslim official. Sikh tradition relates that around 1499 he vanished while bathing in a river and returned after three days saying, "There is no Hindu, there is no Muslim." He then spent some two decades traveling, by tradition as far as Assam, Sri Lanka, Mecca, and Baghdad, conversing with holy men of every kind. His companion was a Muslim musician, Mardana, who accompanied the hymns in which Nanak taught.
His message stood close to that of bhakti poets like Kabir and of Sufi teachers: God is one, without form, and present in every heart, reached through meditation on the divine name, not through idols, pilgrimages, fasting, or priests. He rejected the Caste System and the ritual inferiority of women. Unlike many holy men he insisted that the religious life be lived in the world through work, family, and sharing.
Around 1520 he settled at Kartarpur in Punjab, where followers farmed, prayed, and ate together in a common kitchen. He witnessed Babur's invasion and condemned its violence in his hymns. Before dying in 1539 he named a disciple, not a son, as his successor, creating the guruship that shaped Sikhism.