It’s not free. Actual satellite-based GPS was paid for by the US government for military use, with satellites and ground stations emitting multiple encrypted signals.
After Korean Air Lines Flight 007, which was shot down by the Soviets because the plane (unknowingly) had entered Russian airspace and was presumed a military aircraft, the US government publicized some (but not all) decryption keys for some of those signals, for civil uses. Decryption keys for the more accurate signals remain a secret kept for military use.
Only later did other factions start launching satellites for comparable positioning systems like GLONASS, GALILEO and Beidou.
Latest Answers