GPT4Free uses other sites' connections to OpenAI.
A GitHub project called GPT4free (opens in new tab) allows you to get free access to the GPT4 and GPT3.5 models by funneling those queries through sites like You.com (opens in new tab), Quora (opens in new tab) and CoCalc (opens in new tab) and giving you back the answers. The project is GitHub's most popular new repo, getting 14,000 stars this week.
On the backend, GPT4Free is visiting various API urls that sites like You.com, an AI-powered search engine that employs OpenAI's GPT3.5 model for its answers, use for their own queries. For example, the main GPT4Free script hits the URL https://you.com/api/streamingSearch, feeds it various parameters, and then takes the JSON it returns and formats it. The GPT4Free repo also has scripts that grab data from other sites such as Quora, Forefront, and TheB. Any enterprising developer could use these simple scripts to make their own bot.
If those sites are relying on ad revenue from their sites to offset these API costs, they are losing money because of these queries.
Perhaps more importantly, Xtrekky noted, any of these sites could block external uses of their internal APIs with common security measures.
Xtrekky said that he has advised all the sites that wrote to him that they should secure their APIs, but none of them has done so. So, even if he takes the scripts down from his repo, any other developer could do the same thing.