You're at a beach in Toronto, and it's sweltering.

Do you jump into the lake to cool off? A lot of Torontonians are probably repulsed by the idea. But the reality is, they shouldn't be. Toronto has some of the cleanest beaches in the world.

Shocked?

Well, the city has spent the last few decades cleaning up the shoreline and managing the stormwater system, so it now has eight beaches that qualify for the Blue Flag — an international designation that lets beach-goers know the water is clean enough to swim in.

"To get the blue flag, the beaches have to be safe to swim in by water quality standards for 80 per cent of the days," said Christine Navarro, the associate medical officer for Toronto Public Health.

Parents and children go for a swim at Woodbine Beach, another Blue Flag area in Toronto. (Natalie Nanowski/CBC )

The Greek Islands fly blue flags too

The Blue Flag certification is a global standard from the Foundation for Environmental Education. A municipality's application has to be approved by an international jury. You may have seen those blue banners flying all over Europe, including along the Mediterranean coastline in Italy and Greece.

Toronto's Blue Flag beaches are:

Bluffer's Park Beach.

Centre Island Beach.

Cherry Beach.

Gibraltar Point Beach.

Hanlan's Point Beach.

Kew-Balmy Beach.

Ward's Island Beach.

Woodbine Beach.

Every morning starting in June to the end of August, Toronto lifeguards head out on boats to gather water samples from beaches across the city. What they're looking for, says Navarro, is E. coli levels.

"If it doesn't meet the standards for E. coli, then we would actually have a posting by the lifeguards to indicate that people should not swim," said Navarro.

Where did Toronto's bad rap come from?

Okay, it's true, Toronto's waterfront used to be filthy. Mahesh Patel, who studied the history of the city's waterways, says there's been a lot of work done to change Toronto's reputation, but still people are fixated on the past.

"In the early 1900s, the city had rapid growth and the sewage system was not in place," said Patel, the current manager of Healthy Environments at Toronto Public Health.

Sewage ended up draining into the Humber Bay area.

"There were not enough currents to take away the pollution so as the city got bigger and bigger, what happened was the sewage accumulated in the bay area … There was so much sewage going into the lake that we were seeing contamination everywhere," said Patel.

Mark Mattson, president of Swim Drink Fish, says the city there should be more areas for recreational use than the six beaches opening Monday. He expects crowds that will make safe distancing a challenge. (Paul Smith/CBC )

Skip forward to the 70s and new technologies helped Toronto address the problem. The biggest improvements have happened in the last two decades when the Wet Weather Master Flow Plan was introduced — its measures are ongoing.

The aim is to reduce animal runoff by rebuilding the wetlands and eliminate sewage overflow — both human and animal fecal matter contains E. coli.

At the west and east corners of the city, there are giant tanks built to trap runoff from going into the lake.

"They capture the first few minutes of stormwater, which can be the most heavily contaminated, and prevent it from going into the lake," said Navarro.

9 problem areas left

The water from the tanks is then treated and released.

Mark Mattson, an environmental lawyer and president of Swim Drink Fish, says the city's changes over the years have resulted in very clean water at the blue flag beaches.

Volunteers with Swim Drink Fish test the water in the harbour near Rees Street. (Natalie Nanowski/CBC )

"We have the toughest standard on the Great Lakes. The City of Toronto sticks with the 100 E.coli per 100 millilitres [of water] standard, which is much lower than the Canadian government," said Mattson.

The problem isn't so much with where people are swimming, it's the harbour near the core, says Mattson.

There are nine old combined sewer systems that need to be replaced. These carry both wastewater from toilets and stormwater from roads directly into the lake, and that bacteria remains in those sections for a few days.

"E. coli bacteria is very local. So where you have pipes that are discharging into the lake or into the harbour that's where you're going to see the problems," said Mattson.

Since those areas are filled with ships and there's no lifeguard on duty, they're not approved for swimming, so the city doesn't test them for E. coli. But Swim Drink Fish does, because people use those harbours for water sports.

Volunteers test the water twice a week, and sometimes those areas are nearly as clean as the city's blue flag beaches, other times they fail badly.

"There needs to be better infrastructure here so it doesn't overwhelm the system," said Mattson.