Routers are networking devices operating at layer 3 or a network layer of the OSI (Open System Interconnection) model.
They are responsible for receiving, analyzing, and forwarding data packets among the connected computer networks.
When a data packet arrives, the router inspects the destination address, consults its routing tables to decide the optimal route, and then transfers the packets along this route.