We report on the functionality of a Nb-based superconducting singleflux quantum (SFQ) toggle flip-flop (TFF) circuit, comprising acomplementary superconductor–ferromagnet–superconductor (SFS) Josephsonπ-junction. The SFS junction was used as a phase shifting element inserted in the storage loop of theTFF. The fabricated circuits demonstrated correct functionality with the operation parameter ranges of ± 20%. The applicationof SFS π-junctions makes the SFQ circuits very compact, may substantially improve theirstability, and may also be suitable for integration with Josephson quantum circuits(qubits).