There is a lot to love about living in Massachusetts. From its iconic Cape Cod beaches to the bustling Boston metro area and all the way to the peaceful hills of the Berkshires. Massachusetts truly has something for everyone.

Whether you were born and raised in Massachusetts, or are a transplant to the best state in New England, you know all it has to offer.

Massachusetts boasts a strong economy, affordable living, excellent public schools, and an overall high quality of life. The state has been highlighted as one of the best states to live in the US several times, by publications like US News and World Reports, Niche, and CBS News.

Although there are many great places to live in Massachusetts, no place is perfect and even some of the nicest communities can have some drawbacks. Recently LawnStarter compiled a list of the "dirtiest cities" in the United States and some surprising names from Massachusetts made the list.

But before we get there, let's figure out how the findings were tabulated.

The technology company determined the factors they deemed most relevant to a "dirty city" and then assigned each of those attributes a weight based on its importance, then finally grouped those factors into 4 categories: Pollution, Living Conditions, Infrastructure, and Resident Dissatisfaction.

So how did Massachusetts do?

Seven Massachusetts Cities Make List of Dirtiest Cities in the United States

All in all, we did pretty well. The first Massachusetts city on the list didn't appear until number 36. That city was Lawrence. Check out all the Massachusetts cities that made the list of the top 300, including a surprise at number 92.

35. Lawrence

66. Springfield

92. Newton

145. Fall River

153. Worcester

182. Boston

228. Cambridge

Newton, Massachusetts coming in at number 92 was a surprise for many as the community usually ranks as one of the best and wealthiest places to live in the state. Nationwide it was recently ranked as the fourth wealthy city in America by US News and World Reports.

LOOK: States Sending the Most People to Massachusetts

Stacker compiled a list of states where the most people are moving to Massachusetts using data from the U.S. Census Bureau.

Gallery Credit: Stacker

More From WBEC FM