Tests for phosphorus reduction by increasing magnesium and pH to form struvite (magnesium ammonium phosphate hexahydrate (MgNH4PO4 6(H2O)) were conducted using effluent from a covered earthen anaerobic digester for swine manure. A cone-shaped crystallizer system was constructed in the field and operated with direct pumping of covered digester liquid at a flow rate of 5.4 L/min (1.43 gal/min). Using the field system, 24 combinations of pH increase (0 to 1.5 pH units) and magnesium (Mg) addition (0, 20, 40, and 60 mg/L) were tested in short-term (30-min) tests. Up to 80% of the total phosphorus (TP) could be removed with the highest increases in pH and Mg. About 65% of TP was removed with the combination of 0.5-pH unit increase and addition of 40 mg/L of Mg. To test performance over longer periods, this combination was utilized in 40 tests each of 2-h duration during the period of September 2007 through October 2008. Reductions averaged 55 10% (mean standard deviation) removal of TP and 65 5% removal of orthophosphate phosphorus (OP). Analyses of samples of the solids removed from the crystallizer on six different dates indicated that N, P, and Mg were lower on average than theoretical values for pure struvite (5.71% N, 12.62% P, and 9.90% Mg) by 9.9%, 4.4%, and 6.2%. The solids included 1.8% calcium, indicating calcium compounds were being included in the formed material. Costs and returns were estimated for a commercial scale system and chemical costs and TP removal were estimated at selected levels of Mg addition and increase in pH. The net annual cost of the system for 60% removal of TP from digester effluent for a 1000-sow farrow-to-finish operation was estimated to be $0.0146/kg of live hog marketed.