But the BBC's Sport website was unable to tell the difference between 32-year-old Wilder, an American known as The Bronze Bomber, and British legend Lewis, who is 20 years older.
Lewis responded to the picture caption in good humor, joking about how fit he looked and pondering making a comeback.
The fighters were in Washington for a historic occasion — the posthumous pardoning of Jack Johnson, who was convicted of transporting a woman across state lines for "immoral purposes."
At the time racist attitudes were widespread in the United States and Johnson enraged many Americans because of his relationships with white women.
The Mann Act was a law designed to combat prostitution and all-white jury convicted Johnson despite Lucille Cameron, the 19-year-old white woman he was with, being his girlfriend and later his wife.
Johnson was the reigning world heavyweight champion at the time and two years earlier had defeated "The Great White Hope" Jim Jefferies in a highly-charged fight in Reno, Nevada, that was followed by race riots.
After his conviction Johnson moved to Europe and defended the title several times before losing it in 1915 in Havana, Cuba.
The fight against Jess Willard ended controversially and many boxing historians believe Johnson deliberately threw the fight, possibly in the hope of currying favor and being allowed to return to the US.
"If he was going to throw the fight, I wish he'd done it sooner. It was hotter than hell out there," said Willard afterwards.
Johnson finally returned to the US in 1920, spent a year in prison and died in 1946.
She had led the campaign for a posthumous pardon, a cause which had been championed by Senator John McCain, a Republican from Arizona, and former Senate Majority Leader Harry Reid, a Democrat from Nevada, home of the boxing capital, Las Vegas.
"For so long, my family was deeply ashamed that my uncle went to prison," she told Trump, adding that she didn't find they were related until she was 12 years old.
"By this pardon being issued, that would help to rewrite history and erase the shame and the humiliation that my family felt for my uncle, a great hero," said Ms. Haywood.
"I am taking this very righteous step, I believe, to correct a wrong that occurred in our history and to honor a truly legendary boxing champion," said Trump, who added that the conviction was viewed by many "as a racially-motivated injustice."
"It's my honor to do it. It's about time," the president said.
Actor Sylvester Stallone, the star of the Rocky movies and a huge boxing fan, was also in attendance in the Oval Office.
It was Stallone, a long-time friend, who had brought Johnson's story to the president's attention.
Trump hosted many big boxing matches in the 1990s at his hotels in Atlantic City, New Jersey.
Posthumous pardons are rare in the US and President Barack Obama had declined to offer one to Johnson.
President Bill Clinton pardoned Henry O. Flipper, the first African-American officer to lead the Buffalo Soldiers of the 10th Cavalry Regiment during the Civil War and George W. Bush pardoned Charles Winters, a US volunteer in the Arab-Israeli War convicted of violating the US Neutrality Acts in 1949.