There was a tradition in the hands of the Geonim that if one wishes to drink a fifth cup—he may drink. The Rambam wrote similarly in the eighth chapter, and this is his wording: And afterwards he pours a fourth cup, and completes the Hallel over it, and recites over it the blessing of the song, which is "All Your works shall praise You, Hashem...". And he recites the blessing "Who creates the fruit of the vine," and he does not taste anything afterwards for that entire night except for water. And he may pour a fifth cup and recite over it the Great Hallel, from "Give thanks to Hashem for He is good" until "By the rivers of Babylon." And this cup is not an obligation like the four cups. Thus far his words. And such was their version in the Gemara (118a): On the fifth—he recites the Great Hallel. But in our version it was emended according to the commentary of Rashi and the Rashbam: On the fourth, see there. And the Tur elaborated on this. And there are those who said that on the fourth cup he concludes with the blessing of "Yehalelukha," and on the blessing of the Great Hallel he concludes with the blessing of "Yishtabach." And there are those who said that he drinks the fourth without a concluding blessing, see there. And in the Hagahot Maimoni: However, we do not know of this, and we know only of four cups.
קבלה היתה ביד הגאונים, שאם רוצה לשתות כוס חמישי – שותה. וכן כתב הרמב"ם בפרק שמיני, וזה לשונו: ואחר כך מוזג כוס רביעי, וגומר עליו את ההלל, ואומר עליו ברכת השיר והוא "יהללוך ה' כל מעשיך…". ומברך "בורא פרי הגפן", ואינו טועם אחר כך כלום כל אותו הלילה חוץ מן המים. ויש לו למזוג כוס חמישי ולומר עליו הלל הגדול, מ"הודו לה' כי טוב" עד "על נהרות בבל". וכוס זה אינו חובה כמו ארבעה כוסות. עד כאן לשונו, וכך היתה גירסתם בגמרא (קיח א): חמישי – אומר הלל הגדול. ולפנינו הוגה על פי פירוש רש"י ורשב"ם: רביעי, עיין שם. והטור האריך בזה. ויש שאמרו שבכוס רביעי מסיים בברכת "יהללוך", ובברכת הלל הגדול מסיים בברכת "ישתבח". ויש שאמרו ששותה הרביעי בלא חתימה, עיין שם. ובהגהת מיימוני: מיהו אנן לא ידעינן מזה, ולא ידעינן רק מארבע כוסות.