Applause rang out on Friday in the wind-whipped square as John Paul's simple wooden coffin adorned with a cross and an "M" for Mary was brought out from the basilica and placed on the ground in front of the altar for the Mass.
Bells tolled and the crowd applauded again when the coffin was presented to them one last time and carried back inside, where John Paul II was later buried underneath in the grottos with popes of past centuries.
Dignitaries from more than 80 countries who had gathered in Rome for the Mass all stood as the white-gloved pallbearers carried the coffin through the central portal of the basilica.
The service began with the Gregorian chant Grant him Eternal rest O Lord. Cardinal Joseph Ratzinger, dean of the College of Cardinals, a close confidant of John Paul and a possible successor, referred to him as our "late beloved pope" in a homily that traced his life from his days as a factory worker in Nazi-occupied Poland to the last days of his life as the head of the world's 1.1 billion Catholics.
Ratzinger was interrupted towards the end of the Mass by several minutes of cheers and shouts of "Giovanni Paolo Santo" or "Saint John Paul" from the crowd. The eruption of cheers came before the Litany of Saints chant, in which saints are named.
George Bush (L) and wife Laura
attended with former presidents
Groggy pilgrims who had camped out on the cobblestones had awakened in their sleeping bags to hordes of the faithful stepping over them as they tried to secure a good spot to view the Mass. The square and the boulevard leading to it were a sea of red and white flags waved by pilgrims from John Paul's beloved Poland.
"We just wanted to say goodbye to our father for the last time," said Joanna Zmijewsla, 24, who travelled for 30 hours with her brother Szymon from a town near Kielce, Poland, and arrived at St Peter's at 1am on Friday.
Before the Mass began, American Archbishop James Harvey, head of papal protocol, greeted black-clad dignitaries and religious leaders as they emerged from St Peter's on to the steps. Many of the officials shook Harvey's hand and offered condolences before taking their appointed seats.
Iranian President Muhammad
Khatami (R) attended
Turbans, fezzes, yarmulkes and black lace veils, or mantillas, joined the zucchettos, or skull caps, of Catholic prelates on the basilica's steps in an extraordinary mix of religious and government leaders from around the world.
Dignitaries from more than 80 countries, including the presidents of Syria and Iran, as well as Jewish and Muslim leaders, attended.
Bishop hails pope's efforts
Speaking from Amman, Jordan, Bishop Riyah Abu al-Asal of the Anglican Church in Jerusalem, told Aljazeera the pope touched the world, especially the Middle East.
"We Palestinians appreciate the efforts of the pope, the spiritual leader of all Christians. We appreciate his great work, and pray to God to have mercy on him and place him in heaven," al-Asal said on Friday.
John Paul II was noted for his efforts to promote peace in the Middle East, and al-Asal said he hoped a successor would follow John Paul's example.
"The pope reached all parts of the world offering a helping hand to push peace and justice forward and achieve the legitimate rights of defeated people in the world, including the Arab Palestinian people," al-Asal said.
Ten minutes before the scheduled start of the funeral, the US delegation arrived, headed by President George Bush and including his father, former president George Bush Sr, and former president Bill Clinton.
President Bush and his wife, Laura, sat next to French President Jacques Chirac and his wife.
Air space closed
Rome was at a standstill. On Friday morning, just after midnight, a ban on vehicle traffic took effect throughout the city. Air space was closed and anti-aircraft batteries outside the city were on alert.
Pilgrims arrive for the funeral
Mass at Saint Peter's Square
Naval ships patrolled the Mediterranean coast and the Tiber river near the Vatican City, the tiny sovereign city-state encompassed by the Italian capital.
The pope's death on Saturday evinced an outpouring of affection around the world and brought an estimated four million people to Rome to see the funeral.
At least 300,000 people filled St Peter's Square and Via della Conciliazione, straight to the Tiber.
Giant video screens
Several million more watched on giant video screens set up across Rome in piazzas and at the enormous Circus Maximus, where a group of youngsters wearing T-shirts that read "The boys of Pope John Paul The Great" sold a commemorative booklet about the pontiff.
"I had a special affection for this pope because he loved all people of all religions," said Alex Van Arkabie, 60, who was holding a flag from his native Sri Lanka as he recited the rosary in the Circus Maximus.
The funeral was preceded by an intimate ceremony attended only by high-ranking prelates, who placed a pouch of silver and bronze medals and a scrolled account of the pope's life in his coffin.
John Paul II's longtime private secretary, Archbishop Stanislaw Dziwisz, and the master of the liturgical ceremonies, Archbishop Piero Marini, placed a white silk veil over the pope's face before the coffin was closed.
The pope had lain in state at St Peter's from Monday to Thursday. In four days, an estimated two million pilgrims passed by his body to say their farewells.