Routers and network switches aren't the same hardware—depending on your setup, you may need both.
When it comes to complexity of network connectors, you have got multiple levels, with a switch (hub) at the bottom and a router at the top. A hub is an astonishingly dumb gadget. It accepts a packet ...
In my company's intranet we have a Managed Switch that interconnects all network elements: pf Sense firewall at 192.168.100.1 fiber modem at 192.168.1.1 my brand new D-Link AX1500 Wi-Fi 6 Router, ...