Consumers in the New York City region pay $5.03 on average for out of network ATM fees, the nation's second highest after the Atlanta area, a new study found.

The survey of banks by Manhattan-based financial publisher Bankrate.com includes fees charged by the ATM operator and those charged by the consumer's own financial institution, if any.

The survey included only 10 very large banks in each of 25 metro regions, so it is an incomplete picture. The figures reflect fee increases by large banks after they lost other types of fee income following federal banking legislation enacted after the 2007 to 2009 recession.

"These big banks lost billions in [fee] income so they had to make it up," said president and chief executive Michael Vittorio of First National Bank of Long Island, which is too small to have been affected by the federal legislation.

The lowest ATM fees among the banks surveyed were in the San Francisco area, at $3.85.

Nationally, the average out-of-network ATM fee is at a record-high $4.52, Bankrate.com said, up 4 percent from a year earlier. The average has risen 21 percent over the past five years.

In a statement, the American Bankers Association, based in Washington, said, "Consumers can easily avoid ATM fees, and most do. Out-of-network fees help cover the costs of providing a convenient service so that a bank's customers aren't paying to subsidize non-customers."

Bankrate also looked at checking overdraft fees and found that this region has the nation's tenth highest on average, at $33.58. The national average is at a record-high at $33.07, up 9 percent since 2010. Milwaukee has the nation's highest, $34.79, and San Francisco again has the lowest: $30.35.

Bankrate.com used the Census Bureau definition of the metropolitan area, which includes the five boroughs, and Nassau, Suffolk, Rockland and Westchester counties.

Greg McBride, Bankrate.com's chief financial analyst, said the fee increases follow a pattern set well before the financial crisis. "It's low-hanging fruit in terms of boosting fee income," he said.