Inspired by this article on wikipedia:
https://en.wikipedia.org/wiki/List_...o_ran_for_office_after_leaving_the_presidency have a former President return to some form of political office (preferably not the Presidency) after leaving the Presidency (presumably by not running / term limits).
Ex-Presidency John Quincy Adams served 18 years or so in the House of Representatives.
Ex-President Martin Van Buren ran for President on the Liberty Party ticket in 1848.
Ex-President Millard Fillmore ran for President on the American ("Know-Nothing") Party ticket in 1856.
Ex-President Grover Cleveland regained the Presidency in 1892.
Ex-President Theodore Roosevelt ran for President on the Progressive Party ticket in 1912.
Ex-President William Taft was appointed Chief Justice in 1921.
Possible alternatives...
One easy possibililty is if a President dies in the "lame-duck" period between the election and inauguration, and is succeeded by the Vice President, who was not re-elected. The VP then becomes President for the remaining few weeks of the term, but does not continue in office.
Ex Vice-Presidents have sought or won elective office several times. I see no reason why an ex-VP with a brief term as President might not do likewise.
For instance, VP Hannibal Hamin (1861-1865) later was a U.S. Senator from Maine. If Lincoln had been assassinated before the Second Inauguration, Hamlin would have had a brief span in the Presidency, but it probably wouldn't change his later career.
FDR dies a few months earlier, so that Henry Wallace serves briefly as President. Wallace ran for President on the Progressive Party ticket in 1948; he had served as Secretary of State under Truman in 1945.
Eisenhower could have died of a heart attack in his lame-duck period; Nixon would have probably still run for governor of California, and later for President.
LBJ might have died in his lame-duck period, or resigned from ill health or general depression. Humphrey later served as a U.S. Senator from Minnesota.