Dwarf pencilfish care guide
Also called: Pygmy pencilfish, Nannostomus marginatus, Dwarf pencil fish
The dwarf pencilfish is a tiny, slim, timid South American fish with a gold stripe, kept in groups of 10 or more. It needs a calm, planted, soft and slightly acidic tank with gentle flow and quiet tank mates, and it eats tiny foods.
Dwarf pencilfish need a tank of at least 15 gallons (57 L), a group of 10 or more, and water at 24–27°C (75–81°F) with a pH of 6–7. They grow to about 3.5 cm (1.4 in) and are peaceful.
Plan a tank with dwarf pencilfishSee all tank mates
Dwarf pencilfish quick facts
| Scientific name | Nannostomus marginatus |
|---|---|
| Family | Lebiasinidae |
| Origin | Guyana, Suriname and the Amazon basin, South America |
| Adult size | 3.5 cm (1.4 in) |
| Minimum tank | 15 gallons (57 L), at least 45 cm (18 in) long |
| Temperature | 24–27°C (75–81°F) |
| pH | 6–7 |
| Hardness (GH) | 1–8 dGH |
| Group size | 10 or more (shoaling fish) |
| Temperament | Peaceful |
| Swims at | Middle |
| Diet | Insectivore |
| Care level | Moderate |
| Lifespan | 3–5 years |
| Safe with shrimp? | Mostly (eats baby shrimp) |
| Safe with plants? | Yes |
Tank setup
A group of 10 needs a tank at least 18 in (45 cm) long, and a 15 gallon (57 L) tank gives the group and its quiet tank mates more room. Use a dark substrate, dim light, floating plants and dense planting so the fish feel safe. Keep the filter flow gentle.
How many dwarf pencilfish in a tank?
The smallest common tank that suits dwarf pencilfish is a 15 gallon. Here is roughly how many fit in each size when they are the only fish, based on adult size and waste output. Leave room if you want tank mates.
| Tank | Dwarf pencilfish (alone) |
|---|---|
| 3 gallon | Too small |
| 5 gallon | Too small |
| 10 gallon | Too small |
| 15 gallon | 10–24 |
| 20 gallon | 10–33 |
| 20 gallon long | 10–33 |
| 29 gallon | 10–48 |
| 40 gallon | 10–66 |
| 55 gallon | 10–91 |
| 75 gallon | 10–124 |
| 125 gallon | 10–208 |
What you need for dwarf pencilfish
Sized for a 15 gallon tank, the smallest common size that suits a group of 10 dwarf pencilfish. For a different tank or a mix of fish, use the stocking calculator for a list sized to your plan.
Tank and equipment
- 15 gallon aquarium (tank or kit) (opens Amazon in a new tab)Bigger tanks are more stable and easier for beginners. How to choose
- Adjustable heater, 75 W (opens Amazon in a new tab)Holds about 78 °F (25.5 °C) in a room at 65 °F (18 °C). How to choose
- Aquarium thermometer (opens Amazon in a new tab)Check it daily: heaters can fail stuck on or off. How to choose
- Hang-on-back filter rated 60–90 GPH (opens Amazon in a new tab)Community tank: 4–6 times the tank volume per hour. How to choose
- About 35 lb of aquarium gravel (opens Amazon in a new tab)Enough for a layer about 2 in (5 cm) deep. Smooth gravel suits most community fish. How to choose
- Water conditioner (dechlorinator) (opens Amazon in a new tab)Removes chlorine and chloramine from tap water. Seachem Prime is a popular, concentrated choice. How to choose
- Liquid test kit (ammonia, nitrite, nitrate, pH) (opens Amazon in a new tab)Liquid kits are more accurate than strips. The API Freshwater Master Test Kit is the common choice. How to choose
- Gravel vacuum (siphon) (opens Amazon in a new tab)Cleans the gravel and does the water change in one go. How to choose
- LED aquarium light, about 24 in long (opens Amazon in a new tab)Match the light to the tank length. Basic LEDs grow easy plants. How to choose
Food and extras for dwarf pencilfish
- Micro pellets or flakes for small fish (opens Amazon in a new tab)Small enough for tetras, rasboras and other nano fish.
- Freeze-dried bloodworms or brine shrimp (opens Amazon in a new tab)A treat that carnivores and insect eaters love. Feed it a few times a week.
- Indian almond leaves (opens Amazon in a new tab)Release tannins that soft-water fish like bettas and rams enjoy.
Product links go to Amazon search results. As an Amazon Associate we earn from qualifying purchases, at no extra cost to you. Disclosure.
Water parameters
Keep the water at 24-27 °C (75-81 °F), pH 6.0-7.0 and 1-8 dGH, with soft, stable conditions. Sources give wider ranges, but this narrower band is the safer long-term choice. Avoid swings in pH and temperature, and keep ammonia and nitrite at zero.
Best tank mates for dwarf pencilfish
These popular species share dwarf pencilfish' water needs and temperament. See the full list of 85 good matches.
Betta fish
6.5 cm (2.6 in) · 24–28°C (75–82°F)
Cherry shrimp
3 cm (1.2 in) · 20–27°C (68–81°F)
Nerite snail
2.5 cm (1 in) · 22–27°C (72–81°F)
Guppy
5 cm (2 in) · 22–27°C (72–81°F)
Dwarf gourami
7.5 cm (3 in) · 24–28°C (75–82°F)
Bristlenose pleco
12 cm (4.7 in) · 22–26°C (72–79°F)
Bronze corydoras
7 cm (2.8 in) · 21–26°C (70–79°F)
Assassin snail
2.5 cm (1 in) · 22–27°C (72–81°F)
Avoid keeping dwarf pencilfish with
- Angelfish: Angelfish can eat dwarf pencilfish: they're small enough to fit in its mouth once it's grown.
- Common goldfish: They need different temperatures: Dwarf pencilfish 24–27°C (75–81°F), common goldfish 15–22°C (59–72°F).
- Fancy goldfish: They need different temperatures: Dwarf pencilfish 24–27°C (75–81°F), fancy goldfish 18–23°C (64–73°F).
- Oscar: Oscar can eat dwarf pencilfish: they're small enough to fit in its mouth once it's grown.
- Bala shark: Bala shark can eat dwarf pencilfish: they're small enough to fit in its mouth once it's grown.
- Blue acara: Blue acara can eat dwarf pencilfish: they're small enough to fit in its mouth once it's grown.
Feeding
Dwarf pencilfish pick tiny animal prey from the water. Offer baby brine shrimp, daphnia and other small live or frozen foods often, with micro pellets or finely crushed flakes as a base. Feed small portions, because timid fish may hide and skip meals if the tank is busy.
Behavior
Very peaceful but shy, so they do best with similar-sized, calm fish such as small tetras, Boraras rasboras, corydoras, small plecos or kuhli loaches. Avoid boisterous or large tank mates, which make them hide and stop feeding. They also work as dither fish for dwarf cichlids.
Breeding
Spawning in a home tank is uncommon, though fry sometimes appear in a dense, mature planted tank. For a planned attempt, use a separate container with aged water and fine spawning mops, and remove the adults after 2 to 3 days. Feed the fry tiny foods such as infusoria, then baby brine shrimp.
Tips from experienced keepers
- Keep at least 10. In small groups they hide and look pale.
- Choose calm tank mates only. Busy fish crowd them out at feeding time.
- Dark substrate, floating plants and dim light bring out their color.
- Offer live or frozen food several times a week, not only dry food.
Frequently asked questions
What size tank do dwarf pencilfish need?
A tank at least 18 in (45 cm) long is the minimum, and 15 gallons (57 L) is a comfortable size for a group of 10. Sources give figures from about 10 gallons up, so more room is better.
What are good dwarf pencilfish tank mates?
Small, calm fish such as Boraras rasboras, small tetras, corydoras, small plecos and kuhli loaches. Avoid large, fast or boisterous fish, since pencilfish are shy and may stop eating.
How many dwarf pencilfish should I keep?
Keep at least 10, and more is better. In a large group they are bolder and show more natural behavior.
Sources
We checked these references when writing this page. Values are for healthy long-term keeping, not survival limits. Last reviewed 2026-10-19. See our editorial policy.