Astragalus pycnostachyus is a species of milkvetch known by the common name marsh milkvetch. It is endemic to the coastline of California, where it grows in wet saline habitat such as marshes.
The marsh milkvetch is a perennial herb forming a thick erect clump of hollow, woolly stems 40 to 90 centimeters tall. The leaves are up to 15 centimeters long and are made up of many narrow oval-shaped leaflets. The inflorescence is a cluster of many whitish to greenish flowers each up to a centimeter in length.
The fruit is an inflated, papery legume pod with a small hooked beak at the tip.
The species has two named varieties.