The petrography and mineral chemistry of magnetite from fifteen volcanogenic massive sulfide (VMS) deposits in Canada, and the Lasail VMS deposit in Oman, as well as from two VMS-associated banded iron formations (BIF), Austin Brook (New Brunswick, Canada) and Izok Lake (Nunavut, Canada), were investigated using optical microscopy, electron probe micro-analyzer (EPMA), and laser ablation-inductively coupled plasma-mass spectrometry (LA-ICP-MS). The method of robust estimation for compositional data (robCompositions) was applied to investigate geochemical censored data. Among thirty-seven elements analyzed by EPMA and/or LA-ICP-MS in magnetite from the studied deposits/bedrock lithologies, only the results for Si, Ca, Zr, Al, Mg, Ti, Zn, Co and Ni contain <40% censored values, and thus could be imputed using robCompositions. Imputed censored data were transformed using centered log-ratios to overcome the closure effect on compositional data. Transformed data were classified by partial least squares-discriminant analysis (PLS-DA) to identify different compositional characteristics of magnetite from VMS deposits and BIFs. The integration of petrography and mineral chemistry identifies three types of magnetite in VMS settings: magmatic, hydrothermal, and metamorphic. Magmatic magnetite in VMS deposit host bedrocks is characterized by ilmenite exsolution and may be overprinted by metamorphism. Some VMS deposits contain hydrothermal magnetite, which is intergrown with sulfides, and shows a metamorphic overprint as it is partly replaced by common metamorphic minerals including chlorite, sericite, anthophyllite, and/or actinolite, whereas the majority of the deposits are characterized by metamorphic magnetite formed by replacing pre-existing sulfides and/or silicates, and is intergrown with metamorphic minerals. Among VMS deposits of the Noranda mining district, the West Ansil deposit is characterized by hydrothermal-metamorphic magnetite zoned by inclusion-free cores and Si- and Mg-rich rims. Magnetite from the studied VMS-associated BIFs is also metamorphic in origin. Aluminum, Ti and Zn contents of magnetite can separate BIF from the other mineralized and un-mineralized bedrock lithologies in the studied VMS settings.PLS-DA shows that variable compositions of magnetite slightly discriminate different studied deposits/bedrock lithologies. The geochemical observations suggest that the variation in magnetite chemistry from different VMS settings might be sourced from differences in: 1) the composition and temperature of parental magmas or hydrothermal fluids, 2) the composition of host bedrocks, 3) the composition of co-forming minerals, and 4) oxygen fugacity. PLS-DA distinguishes magnetite compositions from the studied VMS deposits and BIFs from that of the other ore deposit types including Ni–Cu, porphyry Cu-Mo-Au, iron oxide-copper- gold, iron oxide-apatite, and the Bayan Obo REE-Fe-Nb deposit. Magnetite from the VMS settings on average contains lower concentrations of Si, Zr, Al, Mg, Ti, Zn, Co and Ni relative to that from the other mineral deposit types. PLS-DA of magnetite data from VMS deposits and BIFs of the Bathurst mining camp as well as PLS-DA of magnetite compositions from various mineral deposit types yield discrimination models for application to mineral exploration for VMS deposits using indicator minerals in Quaternary lithified sedimentary rocks.