The primary purpose of the Internet Protocol (IP) is to provide logical addressing and routing for packets across interconnected networks. While IP facilitates routing, its fundamental role is defining the addressing scheme that allows data to be directed to the correct destination.