Welcome to the InfinityFree community forum! Good to have you here.
Most people answering here are volunteers. They’re often the fastest source of help. Admin (the only staff member) checks in about once a day for issues on our end.
Volunteers can’t see your account or website. Share what you actually see, like error messages and what happens when you try something. That’s more useful than your theory of what’s wrong.
AI tools often get InfinityFree wrong. If a volunteer’s advice differs from what an AI told you, please try the volunteer’s suggestion first.
Solving an issue is a joint effort. Try the suggestions you get and report back what happened.
Beep boop, I’m a bot! I dug through the forum to get you started. I sometimes get things wrong though, so do with this what you will until a human has a look.
I can’t allow that User-Agent, and nobody can on free hosting. The block comes from the browser security system that every free hosting account has, not from a firewall rule on your site. It can’t be turned off for one path, user agent or IP address. Its list of what doesn’t work includes REST APIs and “AI tools and MCP clients”, so AI Engine Connect calling /wp-json/ falls under it.
The system only lets through clients that can run JavaScript and keep cookies. A tool like AI Engine Connect can’t, so it gets a short HTML page instead of your API response. That page loads /aes.js and sets a __test cookie. Your site’s code never sees the request.
This is the article that lists what’s affected and why:
The article on API access names premium hosting, which doesn’t have this security system, as the way to get inbound API requests working. The other options it lists are using a different service for the API, or having your site make outbound requests instead. Outbound requests from your site aren’t affected.
Your site works for normal visitors because InfinityFree’s security system lets through real browsers (which solve its JavaScript/cookie challenge).
AI Engine Connect, however, sends automated API requests to /wp-json/ from Cloudflare Workers — these can’t run JavaScript or store the security cookie, so the security system blocks them (usually a 403). It isn’t Cloudflare on your side; it’s InfinityFree’s own browser-security system.
Unfortunately, this can’t be changed on free hosting: user-agents can’t be whitelisted, and the security system can’t be disabled per-site. Inbound API access is blocked by design (outbound requests from your site still work).
The only real fixes are to upgrade to premium hosting (iFastNet), which doesn’t have this restriction, or move to a host that allows inbound API access.