OSI Model
gateway - an device that acts on Application/presentation Layer, usually converting something. Usually acts like a proxy. Example: you are on a ipx network and needs to connect to a mainframe (sna only). You use a terminal emulator that send ipx (spx in fact) packets to a GATEWAY, that will handle the conversation with mainframe (thru sna) doing the appropriate conversion
router - a device that connect diferent networks and maintain "routes".
TCP/MODEL
gateway = router

In the begining of TCP/IP, they called the router as "gateway". after OSI model, they started to use "router", but a lot of places still named it as "gateway" (as default gateway on tcp/ip configuration).

Since OSI is (mostly) used only academically (is there such words???) nowadays everybody use gateway/router as synonyms -- they adopt the "tcp/ip naming convention"