Governments do not cease to exist just because a new 'level' is created above them. They simply become part of a greater whole.
After all, United Earth continued to exist even after the formation of the Federation (it simply became another Federation member world), so I see no reason why this wouldn't go further down the proverbial food chain - meaning, Earth's nation-states still exist even after United Earth came into being.
For example: in the USA, individual states still exist, but send representatives to the United States Congress; in Canada, there are individual provincial governments, which are all represented in the national government in Ottawa. Same story here: Earth's nations are represented within the United Earth government, and UE is represented (by Earth's Federation Councillor) in the UFP.