“Hypothetically speaking” and “theoretically speaking” are two different phrases with similar meanings. They descend from the worlds of science and philosophy, and refer to the distinct but similar concepts of “hypothesis” and “theory.” In common conversation they are utilized almost interchangeably. It is only in more careful and measured speech, or when referring to precise scientific concepts, that the difference between them becomes in any way important.
A hypothesis and a theory are both proposed explanations for an existing condition. They are synonymous. A hypothesis is a type of theory and a theory can be a hypothesis. In these phrases, to say “hypothetically speaking” is to imply, “Speaking of a hypothetical situation that has been proposed.” A hypothesis is, in this exact sense, an imaginary situation that is to be considered in the conversation. The speaker is speculating about a world where conditions are a certain way, considering what might follow from those conditions, and possibly advancing a vision of proposed behavior if these things were to be. “Theoretically speaking” implies that there is a proposed underlying principle of some kind being discussed. This can be as vague as discussing the nature of life itself or as completely concrete as the speaker chooses. The distance between these two phrases is very slight, and it is only important when the conversation revolves around a specific hypothesis or a specific theory. For most conversations either phrase will do fine, and the speaker or writer should select between them based on their characteristics of sentence flow, euphony and other aesthetic considerations.