Acidic foods are believed to taste sour because of their hydrogen ion concentration. Scientists believe that the human tongue determines taste through several different channels. acids increase the hydrogen ion concentration, which provides more ions for the tongue. Because the tongue gains ions, it registers the flavor as sour through ion channels.
So we can say all substances that taste sour contains acid. For example : Curd is sour in taste and contains lactic acid.