לרפואת ר' עובדיה בן רחל בתוך שח"י
Is it possible that at one point in history one could harbor a certain belief and be considered within the fold and later the halacha is decided otherwise and a person who harbors those very same beliefs is considered a kofer??
R' Hillel [not Hillel HaZaken] says in Sanhedrin  that there is no Moshiach for Yisrael.
Was he a kofer???
Well, there is a LOOOOOT of literature that attempts to explain this statement. Rashi learns that he means that Hashem will redeem the Jewish people and not a person named Melech Hamoshiach. The Yad Ramah argues with Rashi and understands ki-pshuto that there is no Moshiach. But even according to Rashi, Hillel would be a kofer according to the Rambam who requires that one believe that Moshiach will will from the Davidic dynasty [Hashem is not...]. Others say he meant that in the regular time [בעתה] there will be no Moshiach and Hashem will do the job but if the Geulah would happen in a speedy way [אחישנה] there would be a Moshiach. Others say that he just meant to preclude the opinion of the Christians who believed that Moshiach had come. Rav Yosef Albo maintained that we see from R' Hillel that believing in Moshiach is not a basic principle. [עי' לתשובת השנה פ"ג ה"ו לדיון בנושא].
So the simple meaning is that he is denying one of the Rambam's principles. The Chasam Sofer says that in R' Hillel's time he was not a kofer but afterwards, when the halacha was ruled by the Rambam, one who would harbor such a belief WOULD be a kofer.
Here is the quote from his teshuva:
And here is the Rav ztz"l's illuminating understanding of the statement of Hillel: