Once there was a confrontation between Lord Vishnu and Lord Brahma as to who was superior to them. At the same time, Lord Shiva appeared in the form of a divine pillar which was lighted up both in the downward direction and also in the upward direction. Lord Shiva asked both Lord Brahma and Lord Vishnu that the one who finds an end to this divine light will be declared the most Supreme.
Lord Vishnu sat on a 'Varaha' (wild boar) and went downwards whereas Lord Brahma sat on a 'Swan' and went upwards. Both of them tried very hard but could not find an end to the divine light after which they returned to Lord Shiva.
Lord Vishnu accepted that he could not find an end to the lighted pillar whereas Lord Brahma who was one of the heads used to tell lies saying that he did to find an end and hence he should be declared superior.
Hearing the lie from Lord Brahma, Lord Shiva got very angry and he took the Rudra Avatar (fierce form) of Lord Kal Bhairav. Only with one of his fingers Lord Kaal Bhairav take off the head of Lord Brahma.
As a result, the head of Lord Brahma got stuck in the hands of Kal Bhairav and he attained the 'Brahma Hatya Dosha'. Lord Kal Bhairav went to many places but could not get rid of the Brahma Hatya Dosha.
When lord Kaal Bhairav went to 'Vaikunth Dham' Bhagwan Vishnu guided him to go to Kashi to get rid of the Brahma Hatya Dosha. When lord Kaal Bhairav entered into Kashi the head which was stuck in his finger fell on the ground and he was freed from the Brahma Hatya dosha.
The place where the head of lord Brahma fell was known as the 'Kapal Mochan Teerth'. From that day Lord Kashi Vishwanath appointed Kaal Bhairav as the guardian of the city of Kashi. And gave a blessing that all the devotees who will worship Lord Kaal Bhairav in Kashi all their wishes will be fulfilled and they will attain Shiva Bhakti.
;