We have reconstructed the compositional evolution of the silicate and carbonate melt, and various crystalline phases in the subvolcanic reservoir of Kerimasi Volcano in the East African Rift. Trace element concentrations of silicate and carbonate melt inclusions trapped in nepheline, apatite and magnetite from plutonic afrikandite (clinopyroxene–nepheline–perovskite–magnetite–melilite rock) and calciocarbonatite (calcite–apatite–magnetite–perovskite–monticellite–phlogopite rock) show that liquid immiscibility occurred during the generation of carbonatite magmas from a CO2-rich melilite–nephelinite magma formed at relatively high temperatures (1,100 °C). This carbonatite magma is notably more calcic and less alkaline than that occurring at Oldoinyo Lengai. The CaO-rich (32–41 wt%) nature and alkali-“poor” (at least 7–10 wt% Na2O + K2O) nature of these high-temperature (>1,000 °C) carbonate melts result from strong partitioning of Ca (relative to Mg, Fe and Mn) in the immiscible carbonate and the CaO-rich nature (12–17 wt%) of its silicate parent (e.g., melilite–nephelinite). Evolution of the Kerimasi carbonate magma can result in the formation of natrocarbonatite melts with similar composition to those of Oldoinyo Lengai, but with pronounced depletion in REE and HFSE elements. We suggest that this compositional difference results from the different initial parental magmas, e.g., melilite–nephelinite at Kerimasi and a nephelinite at Oldoinyo Lengai. The difference in parental magma composition led to a significant difference in the fractionating mineral phase assemblage and the element partitioning systematics upon silicate–carbonate melt immiscibility. LA-ICP-MS analysis of coeval silicate and carbonate melt inclusions provides an opportunity to infer carbonate melt/silicate melt partition coefficients for a wide range of elements. These data show that Li, Na, Pb, Ca, Sr, Ba, B, all REE (except Sc), U, V, Nb, Ta, P, Mo, W and S are partitioned into the carbonate melt, whereas Mg, Mn, Fe, Co, Cu, Zn, Al, Sc, Ti, Hf and Zr are partitioned into the silicate melt. Potassium and Rb show no preferential partitioning. Kerimasi melt inclusions show that the immiscible calcic carbonate melt is strongly enriched in Sr, Ba, Pb, LREE, P, W, Mo and S relative to other trace elements. Comparison of our data with experimental results indicates that preferential partitioning of oxidized sulfur (as SO4 2−), Ca and P (as PO4 3−) into the carbonate melt may promote the partitioning of Nb, Ta, Pb and all REE, excluding Sc, into this phase. Therefore, it is suggested that P and S enrichment in calcic carbonate magmas promotes the genesis of REE-rich carbonatites by liquid immiscibility. Our study shows that changes in the partition coefficients of elements between minerals and the coexisting melts along the liquid line of descent are rather significant at Kerimasi. This is why, in addition to the REE, Nb, Ta and Zr are also enriched in Kerimasi calciocarbonatites. We consider significant amounts of apatite and perovskite precipitated from melilite–nephelinite-derived carbonate melt as igneous minerals can have high LREE, Nb and Zr contents relative to other carbonatite minerals.