Donald Trump called the media corrupt and said journalists are enemy of the people. (File)

US President Donald Trump on Saturday accused The New York Times of "a virtual act of treason," after it reported the US is stepping up digital incursions into Russia's electric power grid.

Current and former government officials have described the classified deployment of American computer code inside Russia's power grid and other targets, the Times reported.

The action is intended partly as a warning but also to leave the US poised to conduct cyberstrikes in the event of a major conflict between the US and Russia, the newspaper said.

Trump tweeted that the accusations were "NOT TRUE," calling the media "corrupt" and repeating accusations that journalists are "the enemy of the people."

"Do you believe that the Failing New York Times just did a story stating that the United States is substantially increasing Cyber Attacks on Russia," he wrote.

"This is a virtual act of Treason by a once great paper so desperate for a story, any story, even if bad for our Country."

The Times report came after an investigation by US special counsel Robert Mueller of alleged hacking by Russia's GRU intelligence agency and social media manipulation by Russia's Internet Research Agency to benefit Trump's election campaign.

Mueller detailed a disturbing number of contacts between the Trump campaign and Russia ahead of the 2016 poll.

Trump claimed the report cleared him of wrongdoing. On the question of obstruction of justice, the report did not conclude Trump committed a crime, but Mueller wrote that "it also does not exonerate him."

In its Saturday report, the Times described "broad hesitation to go into detail with Mr Trump about operations against Russia for concern over his reaction -- and the possibility that he might countermand it or discuss it with foreign officials."

The Times also cited National Security Council officials as saying they had no security concerns about the newspaper's reporting on the digital incursions, perhaps indicating that some of the intrusions were meant to be noticed by the Russians.

The New York Times, Washington Post and other publications have issued numerous investigative reports into Trump and his administration, with probes also under way by Congressional committees.

In February the publisher of the Times, AG Sulzberger, said Trump's attacks on the press were "reckless" and "dangerous" and threatened to encourage violence against journalists.

"America's founders believed that a free press was essential to democracy because it is the foundation of an informed, engaged citizenry," he said in a statement.