Macklemore, Mary Lambert, Madonna, Ryan Lewis and Queen Latifah

The Grammy Awards shined a light on marriage equality on Sunday when 33 couples of varying sexual orientations, races and ages tied the knot during Macklemore and Ryan Lewis' performance of "Same Love."

Queen Latifah joined Macklemore, Lewis and featured vocalist Mary Lambert on stage to officiate the weddings of 33 couples who stood in the aisles of the Staples Center in Los Angeles. The crowd looked on as Latifah instructed the couples to exchange rings and proclaimed them all married.

Check out the full list of Grammy winners

After the "I do's," Madonna joined the performance to sing an abbreviated version of "Open Your Heart." The newly married couples were well-received by the audience as Paul McCartney shook hands with the newlyweds and Katy Perry caught a bouquet. Keith Urban was spotted with tears in his eyes.

According to the New York Times, producer Ken Ehrlich pitched the idea to Macklemore and Lewis last fall and began recruiting couples to take part in on-air marriages. All of the couples were required to sign confidentiality agreements.

(Full disclosure: TVGuide.com is owned by CBS, which aired the Grammys.)