You’re invited to a tea party.
I’ll tell you where it is.
First, the IP address of the party. Fun fact: every device that accesses the internet, including the one you’re reading this on, has an IP address. That address is assigned by the network, not the device, so it changes!
Second, knowing the address isn’t enough, you need an invitation! The port number is the invitation that gets you into the right room. Together, IP address + port # form a full address (“123 Main St, Room 4B”) so you arrive in the right room. Otherwise you’ll have an awkward situation walking into that “Micheal Jackson look alike” party you never intended to. Or, in the case of data, an email going to a room ment for web browsing.
Third, how should you behave once you’re there? This is the dress code. Some parties want a formal outfit (secure, encrypted — HTTPS), others are casual (HTTP). The rules tell your data how to present itself once it arrives. This is how APIs work.
Enjoy the party!