"In the second interview, she advocated for the defeat of one Senate candidate and the election of another candidate," according to the office, which is a permanent independent federal investigative and prosecutorial agency.

The report said that in her two TV interviews, "Conway appeared in her official capacity" and in one case "advocated against one Senate candidate and gave an implied endorsement of another candidate."

That investigatory office said it has sent its report on Conway's actions to Trump for "appropriate disciplinary action."

Kellyanne Conway , a top advisor to President Donald Trump , violated the federal law prohibiting some political activity by high-level officials with her comments in two television interviews about the special election for a Senate seat from Alabama , the U.S. Office of Special Counsel said Tuesday.

"Both instances constituted prohibited political activity under the Hatch Act and occurred after Conway received significant training on Hatch Act prohibitions," according to the report from the office.

The agency is not connected to the office of special counsel Robert Mueller, who was appointed by the Justice Department to investigate Russian interference in the 2016 presidential election.

The OSC said it gave Conway the opportunity to respond to the allegations and to its findings, but she did not.

White House spokesman Hogan Gidley said in response to the report: "Kellyanne Conway did not advocate for or against the election of any particular candidate. She simply expressed the President's obvious position that he have people in the House and Senate who support his agenda."

"In fact, Kellyanne's statements actually show her intention and desire to comply with the Hatch Act – as she twice declined to respond to the host's specific invitation to encourage Alabamans to vote for the Republican," Gidley said.

The OSC noted that federal employees, including employees designated as "commissioned officers" in the White House, are subject to the restrictions set by the Hatch Act.

"While commissioned officers may engage in some political activity, they are still barred from using their official authority or influence to interfere with or affect elections," the office said. "Although the President and Vice President are exempt from the Hatch Act, their employees are not."

The office said that on Nov. 20, Conway appeared in her official capacity on Fox News' "Fox & Friends" "and discussed why voters should not support Democrat Doug Jones in the Alabama special election for U.S. Senate."

"On December 6, 2017, Conway appeared in her official capacity on CNN's New Day and discussed why voters should support Republican Roy Moore and not Democrat Doug Jones in the Alabama special election for U.S. Senate," the office said.

Jones ended up winning that race.

"While the Hatch Act allows federal employees to express their views about candidates and political issues as private citizens, it restricts employees from using their official government positions for partisan political purposes, including by trying to influence partisan elections," the report says.

"In passing this law, Congress intended to promote public confidence in the Executive branch by ensuring the federal government is working for all Americans without regard to their political views," the office said.

This isn't the first time Conway has been formally cited for using her official position to make an endorsement that she is not allowed to, by law.

In February 2017, less than a month into Trump's presidency, Conway responded to the news of retailers cutting ties with Ivanka Trump's clothing line by saying on Fox News, "Go buy Ivanka's stuff is what I would tell you. It's a wonderful line. I own some of it. I'm going to give a free commercial here. Go buy it today, everybody."

Rules from the Office of Government Ethics generally prohibit executive branch employees from endorsing products in their official capacities as White House representatives.

Conway was appearing on TV in her official capacity, so she violated that rule.

After members of Congress complained, the White House Office of Legal Counsel reported that lawyers had spoken to Conway twice after the appearance, to reiterate the rules and ensure that they were fully understood.

In a follow-up letter to Congress, then White House deputy counsel Stefan Passantino wrote that after speaking to Conway, "We concluded that Ms. Conway acted inadvertently and is highly unlikely to do so again."

— Additional reporting by CNBC's Kevin Breuninger.