Mayor Bill de Blasio has finally realized what the rest of the country did long ago: He has no chance of being president of the United States.

But that doesn’t mean he’s done torturing New York.

Oh, on the plus side, New Yorkers will no longer have to wince as their mayor abases himself before tiny “crowds” in New Hampshire and Iowa (though we will miss the awkward pictures of him and corndogs).

And (fingers crossed) those pathetic “We’re nearly there, send us $1 to help put us over the top” emails will stop, too.

Or maybe they won’t, since you have to expect de Blasio will rapidly turn his eye to some new side project that he’ll want cash for. His top goal, after all, is to maximize his income and his ambitions when term limits force him out at the end of 2021.

New York law doesn’t give him a golden parachute, so he’s determined to sew his own — however many City Hall favors he has to sell to do it.

Ironically, de Blasio dropped out the day after the state Joint Commission on Public Ethics announced new settlements with donors to his old Campaign for One New York nonprofit — developers who got what they wanted from the city and in turn paid off the mayor’s pocket “charity,” which funded his political ambitions.

When he shut down CONY in the course of dodging prosecution for his corrupt pay-to-play games, the mayor promised to stop taking money from groups or people with city business. Yet his now-done presidential campaign relied overwhelmingly on such donors — particularly the Hotel Trades Council, which has won several City Hall favors.

But all that dirty money wasn’t enough to buy him success in the prez race. He dragged at below 1 percent in the polls, and proved unable to get even token $1 donations to meet the minimum needed to qualify for the Democratic debates.

Now what? You know what he won’t do is pay any more attention to his day job than he absolutely has to — after all, it was boredom with that work that left him chasing hopeless presidential dreams for months. Running the city will be left to his deputy mayors, agency heads and the permanent bureaucracy.

The only exception: whatever projects or people he can use as props to bolster his national progressive reputation — that is, “ensuring that New York City remains the vanguard of progressivism,” as he vowed in his NBC.com column on his withdrawal.

There’s a terrifying statement. What experiments will a bored and ambitious de Blasio foist upon us now?