First, you have to setup an account with an Internet provider. They supply you with a wireless router that plugs into the BT socket. You can then connect by ethernet cable or wireless. You will lose the ability to connect in the event of a power failure as the router is connected to the mains.
OnePlus 5T review: Hands-on