Patrick Dulleck scored the only goal of the game just after the interval.
KSC started the game with their strongest team, taking the friendly as an important test of how ready they are for their first game of the season at FSV Frankfurt on 21 July.
After wasting a good chance through Reinhold Yabo in the first half, Dulleck put them in front early on in the second half, after a wave of substitutions during the interval, with a goal from close range.
The Swiss top-flight side had the chance to level in the 64th minute, but Alhassane Keita's shot over the crossbar from close range.
Karlsruher SC: Orlishausen (46' Reule) - Klingmann (46' Schiek), Gulde (46' Schultz), Mauersberger (46' Gordon), Kempe (46' Vitzthum) - Alibaz (46' Mende), Peitz (46' Varnhagen), Yabo (46' Schwertfeger), Mast (46' Krebs) - Nazarov (46' Marton), Hennings (46' Dulleck).
FC St.Gallen: Herzog - Martic (46' Lüchinger), Montandon (46' Besle), Stocklasa, Lenjani - Vitkieviez (46' Rodriguez), Franin (46' Schönenberger), Janjatovic (46' Nater), Wüthrich (46' Nushi) - Mathys (46' Keita) - Karanovic (46' Cavusevic).
Goals: 0-1 Dulleck (47')