To get rid of algae in your pond without killing the fish you can use beneficial bacteria tablets, barley straw, a UV sterilizer or rake out the algae.
Copper sulfate can also get rid of algae in your pond but it should not really be used as it can kill the fish.
Barley straw is the best way to get rid of and prevent algae growth in your pond without killing the fish as the barley straw releases compounds that inhibit algae growth without harming fish or other aquatic organisms.
Strategically placing pond structures, such as floating plants or installing shade sails, can also limit the amount of direct sunlight reaching the pond.
Also you'll want to increase the number of oxygenating plants on the surface of the pond.
This is perhaps the simplest, long-term solution to keeping water clean and clear.
While plankton algae blooms occur in response to warm and sunny conditions in the summer, the algae growth is supported by high levels of nutrients in the water (most often phosphorus and nitrogen) that may come from fertilizers, manures, septic systems, urban runoff or animal waste entering the pond.
Excess nitrogen and phosphorus cause an overgrowth of algae in a short period of time, also called algae blooms.
The overgrowth of algae consumes oxygen and blocks sunlight from underwater plants.
When the algae eventually dies, the oxygen in the water is consumed.
Adding a variety of aquatic plants to the pond creates competition for nutrients, limiting the availability of resources for algae.
Plants like water lilies and submerged plants provide shade and help maintain a balanced ecosystem.
Natural treatments, such as barley straw, can help prevent algae growth.