According to the attorney general’s office, based on information given to it by Airbnb, the top 40 Airbnb hosts in New York have each grossed at least $400,000 over the past three years, a collective total of over $35 million. The top 100 hosts in that time period have grossed $54 million.

“We began this process in the hopes of collaborating with Airbnb to recover millions of dollars in unpaid taxes and to stop the abuse of Airbnb’s site by operators of illegal hotels,” Matt Mittenthal, a spokesman for Mr. Schneiderman, said in an email. “Airbnb isn’t standing up for average New Yorkers who rent out their apartments from time to time — Airbnb is standing up for highly profitable, illegal businesses that make up a huge chunk of its corporate revenue.”

Some building management companies have begun clampdowns of their own. One of them, TF Cornerstone, recently sent a letter to all of its rental tenants saying that subletting their apartments short-term on websites “creates an overall security risk” and also violates their lease. Another company, Dermer Management, reminded residents in some of its condo buildings that though Super Bowl weekend might seem like a great time to rent out their apartments for extra cash, the buildings’ sublet policy forbids it.

But Airbnb and its hosts say that they serve an important economic function in the city, helping travelers on a budget visit a place so expensive it might otherwise be out of reach, and that they bring those tourists to areas where they might not otherwise go.

“It’s important to remember that almost 90 percent of our hosts have only one listing and it’s the home they live in,” said David Hantman, head of global public policy for Airbnb. “They have asked for a lot of data on regular New Yorkers, and we don’t want to turn it over.”

Ms. Robertson, who began renting out space in her apartment when an illness resulted in high medical bills in a difficult economy, said she had guests only when she was at home. And both she and Leslie, the stay-at-home mother in Brooklyn, said they had declared all of the money they had earned on Airbnb as income.

“Show me the law, and I’ll follow it,” said Leslie, who is in the process of hiring an expediter to help her navigate zoning restrictions against the practice. “When I ask five different lawyers what the law actually means, I get five different answers.”