There's something wrong with what you are doing if you are getting algae buildup.
Is it in a bright area of the room/house? Is it a clear container?
It should be in the dark, and a solid container. This will prevent any algae growth.
In the old days (and this is what I do), people would add a few pieces of Silver to their water to prevent a biofilm from growing. Worked then, works now.
If you are using well water.....stop. Distilling it yourself or even buying it costs next to nothing, and/or a Reverse Osmosis is a good investment for you, your pets, and your misting system. If you want minerals in your water (like many people do), ADD THEM AFTER it has been filtered. Well water is not nearly as good as people so patriotically ensure others it is. Personally I add a few grains of Himalayan pink rock salt to my reverse osmosis for me personally to drink, but there are many options.