A network switch moves data between two network devices, while a router generally routes data between two connected networks.
The router is a device that some think of as a "dispatcher" which sits between two networks and directs data traffic, connecting one network to another. One of the most common examples given of router function is where a LAN router connects a small home network, often wirelessly, to the Internet.
Network switches, on the other hand, move data from one network device to another, efficiently, often by sending a localized signal to only one device, rather than broadcasting it to all local devices. Many network switches are cabled, where switches use MAC addresses or other identifiers to send signals from a dedicated port. Some switches work at multiple levels of the OSI model to do more specialized kinds of data packet control. These are called "multilayer switches."
Being digital should be of more interest than being electronic.- Alan Turing, 1947