ROME — Thousands of people gathered at St. Peter’s Square to wait, chatting and singing in different languages, one eye on the Jumbotrons ­focused on the short stovepipe sticking out of the ­Sistine ­Chapel roof.

Nothing, nothing — and then . . . billowing black smoke. No pope! Shouts, sighs, and a rush of movement as people moved forward to see better, pulling out their cellphones to snap pictures of the signal that no pope had been chosen yet.

“Isn’t this great?” said the Rev. James Statz, a priest from St. Cloud, Minn., beaming amid the crowd under a broad-brimmed rain hat.

The Roman Catholic Church loves ritual, and there is no Catholic ritual as elaborate, as colorful, or as consequential as the process of electing a pope, which officially got underway Tuesday. A riveting spectacle unfolded at St. Peter’s Square, the vast, cobblestoned ellipse partly framed by Bernini’s great marble colonnade. There, Jumbo­trons gave a sea of ­tourists, pilgrims, and passersby a chance to see what was ­going on inside.

The weather escalated the drama: Over the course of the day, there was rain, wind, sun, and, at one point, thunder. One reporter even tweeted something about hail. Nobody seemed to care.

“We just have, like, goose bumps,” said Dina Labanc, 19, of Duquesne University, who is studying here for a semester and arrived with a flock of friends. “We can feel it in the air.”

“It” was history, drama, and, for many Catholics, the presence of God.

“It’s very emotional, a very important moment,” said ­Alessandra Ceraso, 24, of Rome, a literature student and Catholic who was on the piazza with her father. “We wait, and we pray for the cardinals, and we hope in the Spirito Santo,” the Holy Spirit.

The day began at the Basilica of St. Peter, one of the largest churches in the world, where the princes of the church gathered for a Mass in Latin before beginning the process of selecting Pope Benedict XVI’s successor. The cardinals, clad in red choir robes, took seats arrayed around the central altar, ­Bernini’s 95-foot canopy towering overhead. Beneath the altar, it is said, are the bones of St. ­Peter, who the Gospels say was chosen by Jesus to lead his church on Earth.

Cardinal Angelo Sodano, dean of the College of Cardinals, called for unity in the church, asking in his homily that “the Lord, through the pastoral solicitude of the cardinal fathers, may soon grant ­another good shepherd to his holy church.”

Outside, the streets near the Vatican vibrated with chanting and organ music. A limited number of the faithful were ­admitted to the basilica, but thousands gathered on the square to watch.

Ruth Davies, 43, who works for a small Catholic website in London, was among those who managed to get a seat inside.

“It was very beautiful,” she said afterward. “All the red looked very smart.”

She saw several papabile, or papal contenders: Cardinal Timothy Dolan, the archbishop of New York, was “pretty ­smiley” as he processed by, she said, as was Cardinal Luis ­Antonio Tagle from the ­Philippines, a comparatively young cardinal beloved in his home country for his humility and care for the poor. Tagle, she said, helped an elderly cardinal who was having trouble walking.

She also saw Cardinal Sean P. O’Malley, the archbishop of Boston.

“He didn’t do the smiling and waving at everyone,” she said. “He did the looking-quite-seriously.”

A seminarian from Uganda, Remegio Kayiira, 28, who is studying in Rome and who also attended the Mass, said he could feel the intensity of people praying for the cardinals as they prepared for their decision. It was, he said, “a moment I will live to tell for all my life.”

After the Mass, the cardinals returned to the Domus Sanctae Marthae, where they are staying during the papal conclave, to eat lunch and to rest.

Later in the afternoon, the cardinals gathered in the Pauline Chapel inside the Apostolic Palace to prepare for the big moment. Crowds, taking shelter under umbrellas, began to grow as the cardinals began their procession into the Sistine Chapel, where the conclave would begin.

Singing a solemn Gregorian chant, the Litany of the Saints, in Latin, they moved two by two into the Sistine Chapel, slowly taking their places at plywood tables covered with tan felt. The cardinals wore red robes, signifying blood shed by martyrs and the fire of the Holy Spirit, covered with white lacy rochets and red capes, or mozzettas.

The cardinals took an oath of secrecy, speaking the Latin vow in unison. Then, each one approached the altar and swore in Latin to uphold that vow, placing his hand on the Bible open to the Gospels.

Standing before Michelangelo’s enormous fresco, “The Last Judgment,” Monsignor Guido Marini, who as the Vatican’s master of liturgical celebrations is in charge of the ritual, ordered all present but the cardinals to leave the chapel.

“Extra,” he said, with a generous trill of the R, “omnes.”

Everyone out.

A surprisingly large brigade left: monsignors, priests, a couple of nuns, as well as a sword-toting guard in red brocade with an impossibly large white feather in his hat.

Mercifully, for those needing a sign of humanity amid the pomp and circumstance, one monsignor whipped out a tissue and blew his nose.

As Marini slowly closed the tall wooden doors, the vivid blue sky of “The Last Judgment” narrowed into a sliver, then disappeared altogether. Two Swiss guards in full regalia stood guard outside.

About 7 p.m., the time Vatican officials said to watch the chimney for a smoke signal, throngs gathered on St. Peter’s Square. Lights shone on the vast facade of St. Peter’s and lit up flocks of sea gulls wheeling overhead.

A group of teenagers from Madrid sang “Salve Rociera,” a traditional Catholic song from southern Spain that venerates the Virgin of the Dew. Another cluster of young people waved the flag of the ­Philippines. A nun played the guitar.

Olivia Seidl, a student at Christendom College in Virginia who is studying in Rome for the ­semester, marveled at the splendor of the day’s pageantry. She said it made her feel more connected to the roots of her faith.