In this image from video from Senate Television, Sen. Jeff Flake, R-Ariz., speaks on the Senate floor Tuesday, Oct. 24, 2017, at the Capitol in Washington. Flake announced he will not run for re-election in 2018.

Senate TV via AP

WASHINGTON  — Sen. Jeff Flake announced Tuesday he would not run for re-election in 2018, condemning in a speech aimed at President Donald Trump the "flagrant disregard of truth and decency" that is undermining American democracy.

"There are times we must risk our careers. Now is such a time,” the Arizona Republican said in a speech on the floor of the Senate.

Flake, who has criticized the path that the Republican Party has taken under Trump, said the impulse to “threaten and scapegoat" threatens to turn America and the GOP into a "fearful, backward looking people" and a "fearful, backward looking party."

Flake didn't mention Trump by name, but clearly was directing his remarks at the president and his administration.

Flake is a conservative who favors limited government and free markets.

"A political career does not mean much if we are complicit in undermining these values," he said.

After bucking Trump in a state the president won, Flake is bottoming out in polls.

As of Sept. 30, Flake's campaign had $3.4 million on hand. He has continued to raise money — as recently as Thursday, former Secretary of State Condoleezza Rice headlined a fundraiser for him in Arizona, the Arizona Republic reported Tuesday.

He had a tea party primary challenger in Kelli Ward, whom Trump has praised.

Ward, the former state senator from Lake Havasu City, was defeated by Sen. John McCain in last year’s GOP primary.