Those landlords were fined a minimum of $800 for the illegal hotel conversions.
The Bloomberg administration says that 51 of the buildings were vacated for posing immediate hazardous conditions such as the absence of fire alarms and sprinkler systems.
For example, 44 people were staying at one three-family house in Brooklyn.
A New York state law that went into effect last year boosted the city's ability to crack down on illegal hotels.
Bloomberg said Friday that progress is being made but city officials need to maintain vigilance against the safety hazards that illegal hotels create.
Get Eyewitness News Delivered