The Gemara in Masechet Shabbat (42) establishes a Halachic equation between hot liquid inside a Keli Rishon – the original utensil in which something was cooked – and hot liquid poured from a Keli Rishon (called “Iruy Keli Rishon”). Namely, as far as the laws of Shabbat are concerned, both liquid inside a Keli Rishon and liquid poured directly from a Keli Rishon have the capacity to “cook” a raw, solid food item. Whether a person places a raw food inside hot water in a pot or if he pours hot water directly from an urn or pot onto raw food, he has transgressed the Torah prohibition of cooking on Shabbat.
The Rishonim (Medieval Halachic scholars) debate the question of whether or not this Halacha, equating liquid inside a Keli Rishon with liquids poured from a Keli Rishon, applies to pouring on liquids, as well. A number of Rishonim, including the Rashba, Ran and Rambam, rule leniently in this regard, and allow one to pour hot liquid directly from a Keli Rishon onto cold liquid. According to this view, it would be permissible to heat cold water on Shabbat by pouring hot water into it directly from an urn. Tosefot (Talmudic commentaries by the French and German scholars), however, forbid doing so unless one adds less hot water than the amount of cold water in the cup. In their view, one may add a small amount of hot water from a Keli Rishon into a larger amount of cold water, but it is forbidden to add a large amount of hot water into a smaller amount of cold water.
The Shulhan Aruch accepts the lenient position, which allows pouring hot liquid from a Keli Rishon onto cold liquid under all circumstances. Many other authorities, however, including the Ben Ish Hai, Kaf Ha’haim, Rabbi Moshe Halevi and Hacham Ovadia Yosef, accept the stringent ruling of Tosefot. In their view, since we deal here with a potential Torah violation, we must concern ourselves with the stringent position. Therefore, one may not add hot liquid directly from a Keli Rishon onto cold liquid, unless the cold liquid will constitute the majority of the resultant mixture.
The exception to this rule is a case where the liquid had been previously cooked, such as if one has a cup of hot tea or coffee that has cooled, and he wishes to add hot water. According to some views, liquid that has been cooked is no longer subject to the prohibition of cooking on Shabbat even after it has completely cooled. Therefore, this situation is one of a “Sefek Sefeka,” or “double doubt.” The first doubt is whether or not this liquid is subject to “cooking” in the Halachic sense at all, as it had already been cooked, and the second is whether or not pouring onto liquid from a Keli Rishon constitutes cooking. In such a case, then, one may be lenient and add even a significant amount of hot water from a Keli Rishon – such as an urn – into one’s tea or coffee. If, however, the liquid in one’s cup had never been previously cooked, he may add hot liquid only if the added hot liquid constitutes the minority of the mixture.
Summary: One may not add hot liquid directly from a pot or an urn onto raw solid food. One may add hot liquid directly onto cold liquid if the cold liquid had previously been cooked (such as hot tea or coffee that has cooled), or if the amount of hot liquid added is less than the amount of cold liquid in the cup.