Harnessing the most advanced capabilities of quantum technologies will require the ability to control macroscopic quantum states of matter. Quantum magnetic materials provide a valuable platform for realizing highly entangled many-body quantum systems, and have been used to investigate phenomena ranging from quantum phase transitions (QPTs) to fractionalization, topological order and the entanglement structure of the quantum wavefunction. Although multiple studies have controlled their properties by static applied pressures or magnetic fields, dynamical control at the fundamental timescales of their magnetic interactions remains completely unexplored. However, major progress in the technology of ultrafast laser pulses has enabled the dynamical modification of electronic properties, and now we demonstrate the ultrafast control of quantum magnetism. This we achieve by a magnetophononic mechanism, the driving of coherent lattice displacements to produce a resonant excitation of the quantum spin dynamics. Specifically, we apply intense terahertz laser pulses to excite a collective spin state of the quantum antiferromagnet SrCu2(BO3)2 by resonance with the nonlinear mixing frequency of the driven phonons that modulate the magnetic interactions. Our observations indicate a universal mechanism for controlling nonequilibrium quantum many-body physics on timescales many orders of magnitude faster than those achieved to date.