Alerted by authorities in Pennsylvania, officers of the Metropolitan Police Department detained a man from the state, identified as Brian Moles, 43, at around 1 am at the hotel a short distance from the White House.
In his car, they recovered an AR-15 semi-automatic assault style rifle, a handgun and ammunition, police chief Peter Newsham told a news conference. Moles was arrested for illegal possession of firearms.
"The officers and our federal partners... averted a potential disaster in the nation's capital," Newsham said.
Mayor Muriel Bowser described it as a "disturbing incident" that was "resolved quickly and peacefully."
The US Secret Service -- which is tasked with protecting Donald Trump and his family among others -- issued a statement on the incident, saying that "at no time were any Secret Service protectees at risk," and that the investigation was ongoing.
Trump has dined several times at his Washington hotel since taking office in January.
The Secret Service is also tasked with protecting the vice president and family, as well as former US heads of state and their relatives, visiting dignitaries and any other individual designated by the president.
Get the latest election news, live updates and election schedule for Lok Sabha Elections 2019 on ndtv.com/elections. Like us on Facebook or follow us on Twitter and Instagram for updates from each of the 543 parliamentary seats for the 2019 Indian general elections.