In the title compound, C17H17N O4S, the quinoline ring system is nearly planar, with a maximum deviation of 0.0496 (16) Å. A weak intramolecular C—H⋯O interaction is observed. In the crystal, C—H⋯O, S—H⋯N and π–π stacking interactions between the fused benzene ring of quinoline and the pyridine moieties [shortest centroid–centroid distance = 3.6754 (11) Å] are observed. Inversion-related weak C—H⋯O intermolecular interactions diagonally along [010], with R 2 2(10) ring motifs, and S—H⋯N intermolecular interactions diagonally along [100], with R 2 2(8) ring motifs, are present, forming a three-dimensional network structure. No classical hydrogen bonds are observed.