The meeting of cardinals, called the conclave, usually begins with a special morning mass in St. Peter's Basilica. In the afternoon, they walk in a procession to the Sistine Chapel -- known for its famous ceiling painting by Renaissance artist Michelangelo -- to begin the actual voting process.
Ballots are passed out, and cardinals write in a candidate's name and fold it up, then one by one, in order of seniority, they approach an altar and ceremoniously place their ballots into a chalice.
Voting is secret, but ballots are counted in the open. A cardinal needs a vote of two-thirds to ascend to the papacy. If there is no winner, the vote is repeated one time on the first day.
What does the smoke from the chimney mean?
After each vote, the ballots land in the fireplace. If no one has won, a chemical is added to make the smoke black. This lets people waiting in St. Peter's Square below know that there is no new pope yet.
If there is a winner, no chemical is added, and the smoke remains white, telling the world that the conclave has agreed on a new pontiff.
What if there is no winner?
Then they vote again, and again, and again.
The cardinals may cast ballots as many as four times on the second and third days, according to voting rules laid down by John Paul II.
By the end of the third day, if there is still no new pope, they break for a day for prayer, discussions and admonitions from a senior cardinal. This recovery day was instituted by John Paul II.
Voting can go on for another seven rounds of balloting. Still no pope?
John Paul decided to save the cardinals from themselves, if they reach this point. He reduced the necessary result to elect a new pope to an absolute majority -- 50% plus one vote -- if they cross this tiring threshold.
And the vote is to be a runoff between the two most popular candidates from the previous votes.
When there's finally a winner, what next?
The winner must accept the decision for it to be valid. Once he does, the dean asks him to choose a papal name. The oldest cardinal announces the new pope to the crowd in the square from a balcony. The new pope joins him to bless the crowd and the rest of the world.
Past popes have been crowned during a coronation ceremony, but John Paul II refused it, and Benedict followed suit. Both were inaugurated in a mass in St. Peter's Cathedral.