WASHINGTON — President Trump’s time in office has been tumultuous, his term dogged by the special counsel investigation, his major legislative achievements few and his political prospects clouded by the chances of a Democratic Party midterm wave.

But no matter what else happens in the Trump presidency, the retirement of Justice Anthony M. Kennedy, the Supreme Court’s swing voter, set up Mr. Trump to cement a lasting legacy. Given a second Supreme Court vacancy to fill, he appears likely to go down in American history as an unusually influential president.

As the first Republican president to get his judicial nominees confirmed by a simple majority vote, thanks to the abolition of the Senate filibuster rule, Mr. Trump has already broken records in appointing young and highly conservative appellate judges. Now, Mr. Trump can create a new majority bloc on the Supreme Court — one that is far more consistently conservative, and one that can impose its influence over American life long after his presidency ends on issues as diverse as the environment and labor or abortion and civil rights.

If Mr. Trump secures that prospect, he will fulfill the deal that he struck during the 2016 campaign with traditional and movement conservatives who were skeptical of his politics and hesitant about supporting his candidacy. They feared he would pick an idiosyncratic nominee, like a celebrity lawyer he saw on television, rather than an authentic conservative.