HUNTSVILLE, Ala. — When President Trump took the stage here just days before Alabama’s pivotal Republican Senate runoff, he all but revealed his Oval Office deliberations about whether to stand with Senator Luther Strange and risk attaching himself to a potential loser.

“If Luther doesn’t win, they’re not going to say we picked up 25 points in a very short period of time, they’re going say, ‘Donald Trump, the president of the United States, was unable to pull his candidate across the line,’” he predicted to 7,500 Alabamians at a rally on Friday night as Mr. Strange looked on.

His blurting out of his political stage directions was a vintage moment of Trumpian indiscretion. But it also had the benefit of being accurate. The contest between Mr. Strange and Roy Moore, a former State Supreme Court justice and evangelical firebrand, is the most significant test yet of the president’s power to sway the party’s conservative base.

If Mr. Moore wins the runoff on Tuesday, Republican leaders fear he will further widen the split in the party between populists and the establishment. That could embolden more lawmakers to defy the party leadership and encourage other insurgents to challenge Republican incumbents, no matter Mr. Trump’s preference.