Notice the definite article “the” in the phrase “the great city.” That definite article means that John had already introduced this city to his readers (Revelation 11:8). As mentioned in the commentary on that passage, the reference is to any godless civilization that responded to the gospel by murdering the messengers and rejoicing in doing so.
19 The great city was split into three parts, and the cities of the nations fell, and God remembered Babylon the great, to make her drain the cup of the wine of the fury of his wrath.