Ptpmeg is a cytoplasmic tyrosine phosphatase containing FERM and PDZ domains. Drosophila Ptpmeg and its vertebrate homologs PTPN3 and PTPN4 are expressed in the nervous system, but their developmental functions have been unknown. We found that ptpmeg is involved in neuronal circuit formation in the Drosophila central brain, regulating both the establishment and the stabilization of axonal projection patterns. In ptpmeg mutants, mushroom body (MB) axon branches are elaborated normally, but the projection patterns in many hemispheres become progressively abnormal as the animals reach adulthood. The two branches of MB alpha/beta neurons are affected by ptpmeg in different ways; ptpmeg activity inhibits alpha lobe branch retraction while preventing beta lobe branch overextension. The phosphatase activity of Ptpmeg is essential for both alpha and beta lobe formation, but the FERM domain is required only for preventing alpha lobe retraction, suggesting that Ptpmeg has distinct roles in regulating the formation of alpha and beta lobes. ptpmeg is also important for the formation of the ellipsoid body (EB), where it influences the pathfinding of EB axons. ptpmeg function in neurons is sufficient to support normal wiring of both the EB and MB. However, ptpmeg does not act in either MB or EB neurons, implicating ptpmeg in the regulation of cell-cell signaling events that control the behavior of these axons.