Quinine is used alone or with other medications to treat malaria (a serious or life-threatening illness that is spread by mosquitos in certain parts of the world). Quinine should not be used to prevent malaria. Quinine is in a class of medications called antimalarials. It works by killing the organisms that cause malaria.