Water & maintenance

How to get rid of algae in a fish tank: types and fixes

By The FishFits team · Updated

To get rid of algae in a fish tank, identify the type, then fix the imbalance that feeds it: run the light 6–8 hours a day on a timer, keep the tank out of direct sun, feed less, and keep nitrate below 40 ppm (ideally 20 ppm) with weekly water changes. Remove what's there by scraping, scrubbing and siphoning, then use a targeted fix for stubborn types: a UV sterilizer for green water, more flow and cleaning for cyanobacteria, and 3% hydrogen peroxide sprayed on black beard algae out of the water. Algae eaters help with upkeep but never fix the cause.

Algae in a fish tank is a symptom, not the problem. It grows when there is more light and more nutrients than your plants can use. Scraping it off buys you a week; fixing the balance stops it coming back.

Some algae is normal in every healthy tank. The realistic goal is algae you can keep in check with a quick wipe at each water change. Start by working out which type you have, because the fixes differ.

Identify your algae first

Type What it looks like Usual causes Fix
Green dust Soft green haze on the glass. Wipes off easily but is back within days New or unsettled tank, extra nitrogen waste; in planted tanks, strong light with too few plants Leave the glass for 2–3 weeks, then scrape it all off at once and siphon it out
Green spot Hard, round green dots on glass and slow leaves such as anubias. Won’t wipe off Too much light; in planted tanks, low phosphate Razor blade on glass, plastic card on acrylic; shorter light; nerite snails
Hair or thread Green strands on plants, wood and decor, like wet hair Too much light, excess iron, or too few nutrients for a long light period Twist it out with a toothbrush; shorten the light; balance fertilizer; amano shrimp
Black beard Dense black or gray tufts on wood, rock, leaf edges and filter outlets. Firmly attached Not fully understood; linked to waste buildup and, in CO2-injected tanks, unstable CO2 Trim leaves; 3% hydrogen peroxide out of the water; Siamese algae eaters; patience
Brown diatoms Brown, dusty coating on glass, gravel and leaves. Wipes off easily New tanks with spare silicate and phosphate Wipe and siphon; fades as the tank matures; otocinclus and snails eat it
Blue-green “algae” (cyanobacteria) Slimy dark green, blue-green or reddish sheets over gravel and plants. Peels off, smells musty Dead spots with poor flow, debris in the substrate, overfeeding Siphon, vacuum, change water, add flow; blackout or an erythromycin treatment if stubborn
Green water The whole tank turns pea-soup green Too much light (especially sun), excess nutrients, ammonia in an uncycled tank UV sterilizer (2–3 days) or a full blackout of 7–10 days

Not sure? If it wipes off with a fingertip, it’s green dust or diatoms. If it lifts off in a slimy, smelly sheet, it’s cyanobacteria, a bacterium that needs its own treatment.

Why algae grows: light and nutrients

Algae and plants want the same things: light, nitrogen, phosphate, iron and carbon dioxide. Algae grows faster and takes any surplus. An outbreak starts when one side outruns the other:

  • Too much light for the nutrients. A bright light running 10–12 hours over a lightly planted tank often ends in hair or green spot algae.
  • Too many nutrients for the light and plants. Overfeeding, too many fish, rotting leaves or a fertilizer overdose lead to green water, hair algae and cyanobacteria.

So cutting back isn’t always the answer. If a planted tank’s plants look pale and have stopped growing, the plants may be starving, and a balanced fertilizer is the fix.

Get the light right

Setup Light per day Notes
Fish only, no live plants 6–8 hours The light is only for viewing, so less is fine
New planted tank 6–8 hours Start at 20–40% brightness if your light dims
Established planted tank 8–10 hours Go longer only if plants grow well and algae stays low
  • Put the light on an outlet timer so it runs the same hours every day.
  • Keep the tank out of direct sunlight, the classic trigger for green water.
  • No lights overnight, including blue “moonlight” modes.
  • If the light can’t be dimmed, raise it or cover some of the LEDs.

Cut the nutrient surplus

In a tank without live plants, most excess nutrients come from food and fish waste.

  • Feed less. Give only what your fish finish in a minute or two.
  • Keep nitrate below 40 ppm, ideally 20 ppm or less, with regular water changes. How much water to change has the schedule and the nitrate math.
  • Test your tap water. Some supplies already contain nitrate, and many utilities add phosphate to stop lead leaching from pipes. If your tap is high in either, water changes can’t take the tank below that level.
  • Clear out the waste. Vacuum the gravel, remove dead leaves, and rinse clogged filter media in old tank water.
  • Check your stocking. Too many fish means nitrate rises faster than water changes remove it. The stocking calculator shows whether waste is your limiting factor.

Use plants as competition

Healthy plants are the best long-term algae control because they use the same nutrients. Fast-growing stem plants and floating plants compete hardest; slow growers such as anubias and java fern barely compete, so their old leaves often collect green spot and black beard algae. Easy aquarium plants lists fast, hardy species that grow without CO2.

How to get rid of algae step by step

  1. Identify the type with the table above. Take a photo so you can compare progress later.
  2. Test the water. Check ammonia, nitrite and nitrate in the tank, and nitrate in your tap water. Any ammonia in an established tank points to overfeeding, a dead fish or a filter problem.
  3. Set the light and feeding. Light on a timer for 6–8 hours a day, no direct sun, and only as much food as is eaten in a minute or two.
  4. Remove what you can by hand. Scrape the glass, scrub decor, twist out hair algae and trim badly covered leaves.
  5. Change 25–50% of the water, vacuuming the gravel to pull out loose algae. If the tank hasn’t had a water change in months, change 25% now and repeat every day or two instead.
  6. Fix the specific cause for your type (below).
  7. Change one thing at a time and wait 2–3 weeks before judging. If you change light, fertilizer and fish in the same week, you won’t know what worked.
  8. Add a cleanup crew last, to keep up with what’s left.

Fixing the stubborn types

Green water

Green water is floating single-celled algae that multiplies faster than water changes can remove it.

  • UV sterilizer. Water pumped past a UV bulb kills the floating cells, and most tanks clear in 2–3 days. Pick a unit rated for your tank volume and keep the flow within the maker’s range.
  • Blackout. Cover the tank completely for 7–10 days (steps below). It costs nothing but is hard on plants.
  • Then remove the cause: sunlight, a long photoperiod, overfeeding or extra fertilizer. In a new tank it often follows an ammonia spike, so test for ammonia and finish cycling the tank. Cloudy fish tank water covers green water alongside white and brown water.

How to do a blackout

  1. Change some water and remove as much algae as you can.
  2. Turn off the light and cover every side with blankets or black trash bags. No gaps.
  3. Keep the filter and heater running and add an air stone, because dying algae uses oxygen.
  4. Feed lightly every other day, lifting a corner just long enough to check the fish.
  5. Uncover after 3–7 days for cyanobacteria or 7–10 days for green water. Change 25–50% of the water and test for ammonia.
  6. Bring the light back on a shorter schedule than before.

If fish gasp at the surface, uncover the tank, add aeration and change some water.

Blue-green algae (cyanobacteria)

Cyanobacteria often starts in a corner with poor flow or along the front of the substrate, and algae eaters generally won’t touch it.

  1. Siphon out as much as you can, vacuum the gravel and change some water.
  2. Add flow. Point the filter outlet across dead spots, add an air stone or small powerhead, and move decor that blocks flow.
  3. Clean the filter if its flow has dropped, rinsing media in old tank water.
  4. Feed less, and repeat the siphoning every few days.

In heavily planted tanks it sometimes appears when nitrate runs out, because many cyanobacteria can use nitrogen gas dissolved in the water and plants can’t. If a planted tank tests at 0 ppm nitrate, a fertilizer with nitrogen can help.

If it returns after 2–3 weeks of better flow and cleaning, the last resorts are a 3–7 day blackout or an erythromycin-based aquarium treatment. Erythromycin is an antibiotic that needs a prescription in some countries, so ask an aquatic vet if unsure, follow the label exactly and run an air stone during treatment. Neither fix lasts if the dead spots and buried waste stay.

Black beard algae

Black beard algae (BBA) is a red alga, and when treatment kills it, it turns pinkish-red and then white or clear. It is slow to establish and slow to clear, so expect months rather than weeks.

  • Trim it. Cut off and throw away covered leaves, especially old leaves on slow plants.
  • Spot-treat with 3% hydrogen peroxide out of the water. Take the rock, wood or hardy plant out of the tank, or lower the water until the algae is exposed. Spray the algae, wait about 5 minutes, then rinse the item (or refill the tank). Use a shorter exposure on delicate plants and mosses.
  • Let grazers finish it. Weakened BBA is easier for amano shrimp and Siamese algae eaters to eat. The Siamese algae eater is one of the few fish that eat BBA, but it needs 55 gallons (208 L) and grazes less as an adult.
  • Be careful with liquid carbon. Hobbyists report less BBA with glutaraldehyde-based “liquid carbon”, but it isn’t sold as an algicide and large doses can melt Vallisneria. Stick to the label dose.
  • Keep conditions steady: regular water changes, no waste buildup, good flow, and in CO2-injected tanks, CO2 that holds steady through the whole light period.

Green dust and green spot algae

Wiping green dust algae early just spreads it. Many planted-tank keepers beat it by waiting: leave the glass for 2–3 weeks until the film thickens and flakes, then scrape it all off at once and siphon out the pieces during a large water change. It often doesn’t return.

Green spot algae never wipes off. Use a razor blade on glass (a plastic card on acrylic), remove the worst leaves, shorten the light, and in a bright planted tank check that phosphate isn’t running out.

What algae eaters can and can’t do

Algae eaters are maintenance, not a cure. They add waste, which feeds algae, and many go hungry once it’s gone, so plan to feed wafers or blanched vegetables. Best algae eaters has picks by tank size, including small and betta tanks.

Animal Best against Limits
Otocinclus Diatoms, soft film on glass and leaves Group of 6 or more in 20 gallons (76 L) or larger; mature tanks only; often arrives underfed
Amano shrimp Hair algae, some BBA Group of 3 or more in 10 gallons (38 L) or larger; graze less when well fed; large fish eat them
Nerite snail Green spot, diatoms, film on glass and decor Lays hard white eggs (they don’t hatch in fresh water); needs hard, mineral-rich water for its shell
Siamese algae eater Hair algae and BBA, mainly while young 55 gallons (208 L), 4 ft (120 cm) long; about 6 in (15 cm); adults prefer fish food
Bristlenose pleco Film on glass, wood and rock; diatoms About 4.7 in (12 cm); 20 gallons (76 L) or larger; needs wafers and vegetables too
Cherry shrimp Biofilm and soft algae in nooks Colony of 10 or more in 5 gallons (19 L) or larger; small appetites, so slow work

None of them eat cyanobacteria reliably, and none clear green water. Skip the two classic mistakes: the common pleco grows to about 16 in (40 cm) and needs a 150-gallon (568 L) tank 6 ft (180 cm) long, and the Chinese algae eater reaches 8 in (20 cm), needs about 80 gallons (304 L) and turns aggressive as an adult.

Common algae mistakes

Mistake Why it backfires Do this instead
Dosing a broad algaecide Rotting algae uses oxygen and releases nutrients, so it comes back; some products harm shrimp, snails or plants Remove algae by hand and fix the cause; always read the label
Scrubbing everything and replacing filter media It kills filter bacteria, ammonia rises and algae follows Rinse media in old tank water, and only when flow drops
Adding fertilizer to a tank with few plants Nothing uses it except algae Match fertilizer to plant mass, or skip it in fish-only tanks
Buying an algae eater as the fix It adds waste and can’t keep up with the cause Fix light and feeding first, then add grazers
Aiming for zero algae Some algae is normal and feeds grazers Leave a little on the back glass and wood

Gear mentioned in this guide

Product links go to Amazon search results. As an Amazon Associate we earn from qualifying purchases, at no extra cost to you. Disclosure.

Frequently asked questions

Why does algae keep coming back in my fish tank?

Because the cause is still there. Scraping and algae eaters remove the algae, but if the light runs too long, sunlight reaches the tank, or food and fish waste keep nitrate and phosphate high, it regrows within days or weeks. Fix the light and nutrient balance first, then clean.

Is algae bad for fish?

Most aquarium algae is harmless, and many fish and shrimp graze on it. The problems are heavy blooms: thick green water or cyanobacteria can lower oxygen at night, smother plants, and signal that nutrients or ammonia are too high.

Should I turn off my aquarium light to kill algae?

A full blackout of 7–10 days can clear green water, and 3–7 days can knock back cyanobacteria, but it is hard on plants and the algae returns if the cause is not fixed. For everyday algae, shorten the light to 6–8 hours a day on a timer instead.

How long does it take to get rid of algae in a fish tank?

It depends on the type. A UV sterilizer clears green water in 2–3 days, green dust algae usually takes 2–3 weeks, diatoms fade as a new tank matures, and black beard algae can take months. Give each change 2–3 weeks before you judge it.

Will an algae eater get rid of my algae?

Only the types it eats, and only once the cause is fixed. Nerite snails handle green spot, otocinclus handle diatoms and soft film, and amano shrimp handle hair algae, but no algae eater clears green water or reliably eats cyanobacteria.

Sources