History of Sivaratri
Once when everything in all the worlds got reduced into Lord Siva, in that darkness of nothing present, the mother pArvati worshipped Lord Siva in the Agamic way with great devotion. The parameshwar pleased by Her prayer blessed Her. She asked for the benefit of all the creatures that in future whoever worships the Lord on the Siva rAtri day with devotion, they should be blessed and should be given the ultimate liberation. The pashupati granted that showing way for all of us to get blessed easily.
When Brahma and Vishnu fought between themselves as "who is the greatest", Lord Siva appeared before them as a pillar of fire. They were not able to find the starting and end of that pillar. This day is Thirukkaarthikai.(1)
Then Brahma and Mahavishnu repented for their mistake and prayed to Lord Siva for forgiving their sin worshiping the Siva lingam which is the form of the flame. In the night of Siva rathri Lord Siva appeared before them and blessed them. Devotees pray the God throughout the night of Siva rathri by performing Abisheka, chanting and other holy deeds.
Every month in Krishna paksha chathurdhasi (fourteenth moonday) is called masa Siva rathri. The one that comes in the month of "Masi" (mid February to mid March) is called Maha Siva rathri. This is considered as the most important vrata by the devotees.
There are many incidents told about the greatness of this day. Once a hunter in a jungle after searching throughout the jungle, was quite tired and could not get any animal. In the nightfall a tiger started chasing him. to escape from that he climbed a tree. That was a Bilva tree. The tiger sat under the tree waiting for him to come down. The hunter who sat on a branch of the tree was quite tense and didn't want to sleep. He was plucking the leaves and putting down as he was not able to be idle. Below the tree there was a Siva lingam. The whole night went on like this. God was pleased with the Upavasa (hunger) and the Pooja the hunter and the tiger did even without knowledge. He is the peak of the grace. He gave the hunter and the tiger "Moksha".
In a Siva temple on a Maha Siva rathri day the lamp kept in the altar was very dim. That time a mouse which came take its prey touched the flame. Due to the heat it moved its head immediately. In the process it kindled the lamp and the altar was illuminated well. Lord Siva, pleased by this deed made the mouse Mahabali, the renowned asura king.
There are many incidents like this told in our Puraanas. If we do the vrata with pure devotion and love there can be no doubt about getting the Grace of the Almighty.
When is sivaratri observed
ska.ndha purANam describes about four Siva rAtris. The first one is nitya SivarAtri (daily SivarAtri - every night). The second one is the mAsa SivarAtri which is observed on the kR^iShNa paxa chaturdasi (fourteenth moonday on the moons diminishing phase). The third one is the mAga prathamAdi SivarAtri which is observed for the thirteen days starting from prathama titi in the month mAga (mAsi) and on the chaturdasi night the Lord is worshiped throughout the night.
The fourth one is observed on the mAsi (mAga) month kR^iShNa paxa chaturdasi. This is the one observed in a widespread manner. It is also called mahA SivarAtri.
Way of observing Sivaratri
Getting up early in the morning one meditates on the Infinitely Auspicious, ornated with thousands of splendid garlands, Who is in the form of the holy symbol of Siva(mahA lingam). Bathing and staying clean the worship of Lord Siva in the form of Siva li.ngam is done in the four jamas of the night (four equal time intervals of the night). (Note that the li.nga worship is explicitly mentioned for this vratam as this is the time the God out of Its grace for the benefit of pashus appeared in a formless-form that is a symbol (li.ngam) from Its true nature of formlessness.)