A molecularly imprinted polymer (MIP) was formed using an inorganic polymer by a sol-gel process. The monomers which were used to synthesize the inorganic polymer were tetraethoxysilane (TEOS), triethoxymethylsilane (MTES), and triethoxyphenylsilane (PTES). Caffeine was chosen as a template for the molecular imprinting, and theophylline was chosen as the analogous counterpart compound. The discriminating ability of the synthesized MIP to these twocompounds was estimated in this study. The MIP showed the highest discriminating ability when the ratio of TEOS:MTES:PTES in the synthesis of the inorganic polymer was 1:1:3, the reaction temperature was 50˚C, and the pH of the reaction system was ~6.5.