Struvite crystallization has been considered a promising approach to recover phosphorus from wastewater. However, its practical application is limited, probably because of the high cost of magnesium (Mg). In this study, a comprehensive economic analysis was conducted using five Mg sources (MgCl2, MgSO4, MgO, Mg(OH)2, and bittern) during the operation of a pilot-scale fluidized bed reactor (FBR), using swine wastewater as the case matrix. First, the economic operating conditions were investigated, and subsequently, the performance and the costs of the five Mg sources were compared. The results indicated that the FBR could be operated most economically at pH of 8.5 and Mg to phosphorus (Mg/P) molar ratio of 1.5. Under these conditions, no significant differences in phosphorus removal and product quality could be found between the five Mg sources. Selecting the most economical Mg source was thus highly dependent on the prices of the reagents and Mg sources. Low-solubility Mg sources were preferable when NaOH was priced higher, while high-solubility Mg sources proved more economical when HNO3 was expensive. The bittern was the most economical choice only when the distances for total inorganic orthophosphate removal and struvite recovery were shorter than 40 and 270 km, respectively. The current study provides an overview of the economic selection of an Mg source, which can help reduce the cost of struvite crystallization.