The Federal Reserve is poised to raise its benchmark interest rate in mid-March, significantly sooner than investors had expected, as it moves to keep pace with a wave of economic optimism that started with the election of President Trump.

In an unusually clear statement about a pending decision, the Fed chairwoman, Janet L. Yellen, said on Friday in Chicago that the central bank was likely to act at its next policy-making meeting — barring any unpleasant economic surprises.

Ms. Yellen added that the Fed still expected to raise rates twice more later in the year, which she said would bring the benchmark rate close to a level that the Fed regards as neutral, with low rates no longer providing an inducement for borrowing and risk-taking. That outlook signals that an end is finally in sight for the Fed’s economic stimulus campaign, devised during the depths of the financial crisis more than eight years ago.

Stanley Fischer, the Fed’s vice chairman, delivered the same message at the same time at a conference in New York. “We’ve seen a lot of substantial change in a relatively short time,” Mr. Fischer said of the postelection shift in economic conditions. “There is almost no economic indicator that has come in badly in the last three months.”