Several dozen guests attended the event, which took place in the East Room of the White House.
Around 5:20 p.m., Robert Trump’s casket was transferred to a hearse waiting outside.
President Trump, first lady Melania Trump, and several family members followed the pallbearers down the steps as bagpipes played the hymn “Abide With Me.”
The family members stood at attention and held hands for a couple of moments as the casket was placed inside the vehicle.
A few dozen family and friends stood nearby on the White House steps. As the hearse drove away, the president and first lady returned to the residence and some in the group embraced in an effort to provide comfort.
The event marked the first White House funeral service since 1963 when president John F. Kennedy was assassinated.
“Robert, I Love You. Rest In Peace!” the president wrote on Twitter late Friday.
When Trump explained why he wanted to have a service for his brother at the White House, he said: “I think he’d be greatly honored. He loves our country. He loved our country so much. He was so proud of what we were doing and what we are doing for our country. So I think it would be appropriate.”
Robert Trump, the youngest of the five Trump siblings, died on Aug. 15 at the age of 71, and would have turned 72 in 11 days. The cause of death was not disclosed.
“It is with heavy heart I share that my wonderful brother, Robert, peacefully passed away tonight,” the president said in a statement on Aug. 15.
“He was not just my brother, he was my best friend. He will be greatly missed, but we will meet again. His memory will live on in my heart forever. Robert, I love you. Rest in peace.”
Just a day prior, the president visited him at New York-Presbyterian/Weill Cornell Medical Center. Trump told reporters on Aug. 14 that his brother was “having a hard time” with an undisclosed illness.
Robert Trump worked in corporate finance on Wall Street before joining the family business as a top executive in the Trump Organization. He retired to upstate New York where he supported local charities, including being a trustee for the Angels of Light, a nonprofit that gives holiday presents to children with life-threatening illnesses. He also donated to a horse rescue group.
President Trump told Fox News in an interview on Aug. 17 that his brother Robert was his “biggest fan.” Robert Trump had previously told the New York Post in 2016 that he supported his brother’s presidential campaign “1,000 percent.”