  Angle-resolved photoemission spectroscopy (ARPES) is a powerful tool for
probing the momentum-resolved single-particle spectral function of materials.
Historically, $\textit{in situ}$ magnetic fields have been carefully avoided as
they are detrimental to the control of photoelectron trajectory during the
photoelectron detection process. However, magnetic field is an important
experimental knob for both probing and tuning symmetry-breaking phases and
electronic topology in quantum materials. In this paper, we introduce an easily
implementable method for realizing an $\textit{in situ}$ tunable magnetic field
at the sample position in an ARPES experiment and analyze magnetic field
induced artifacts in ARPES data. Specifically, we identified and quantified
three distinct extrinsic effects of a magnetic field: Fermi surface rotation,
momentum shrinking, and momentum broadening. We examined these effects in three
prototypical quantum materials, i.e., a topological insulator (Bi$_2$Se$_3$),
an iron-based superconductor (LiFeAs), and a cuprate superconductor
(Bi$_2$Sr$_2$CaCu$_2$O$_{8+x}$), and demonstrate the feasibility of ARPES
measurements in the presence of a controllable magnetic field. Our studies lay
the foundation for the future development of the technique and interpretation
of ARPES measurements of field-tunable quantum phases.
