Recent data on U.S. inflation have been “a bit on the high side,” but generally provide evidence that price levels are moving back toward the Federal Reserve‘s 2% target, Fed Chairwoman Janet Yellen said Wednesday.

Price gains across the U.S. economy have been sluggish over the past two years. But several gauges of inflation have gained traction in recent months. The Fed’s preferred gauge, the Commerce Department’s personal consumption expenditures price index, rose 1.6% in April from a year earlier. Another closely watched gauge, the consumer-price index, was up 2.1% in May from a year earlier, the Labor Department said Tuesday.

“Recent readings on, for example, the CPI index have been a bit on the high side,” but the data are “noisy,” Ms. Yellen said at a press conference following a meeting of the Fed’s policymaking committee. “I think it’s important to remember that, broadly speaking, inflation is evolving in line with the committee’s expectations. The committee has expected a gradual return in inflation toward its 2% objective, and I think the recent evidence that we’ve seen, abstracting from the noise, suggests that we are moving back gradually, over time, toward our 2% objective.”

Ms. Yellen said the Fed “would not willingly see a prolonged period in which inflation persistently runs below our objective or above our objective.”

She did, however, indicate the Fed might tolerate inflation overshooting the 2% goal if the U.S. economy were still far from the Fed’s goal of maximum employment. Right now, sluggish inflation and elevated unemployment both call for accommodative policy, but “there could conceivably arise policy conflicts or trade-offs somewhere down the road,” Ms. Yellen said.

In that event, she said, “we would consider, in deciding on a policy, just how far we are from achieving each of the objectives and if the distance from achieving an objective is particularly large, it would be consistent with the balanced approach that we would tolerate some movement in the opposite direction on the other objective.”

About Real Time Economics

Real Time Economics offers exclusive news, analysis and commentary on the U.S. and global economy, central bank policy and economics. Send news items, comments and questions to the editors and reporters below or email realtimeeconomics@wsj.com.