Want to generate AI images in Aimogen Pro for free without relying on expensive external APIs? You can do it using Cloudflare Workers AI in just a few minutes.
First, visit the Cloudflare Dashboard and log into your account. If you don’t already have one, create a free account first.
From the left menu, go to Compute -> Workers & Pages.
Click the “Create application” button, then choose “Start with Hello World”.
Deploy the worker once so Cloudflare creates the project for you.
After deployment, open your worker and click “Overview”.
Click “Add Binding”.
Click “+ Binding”.
Select “Workers AI” from the list and click ‘Add Binding’.
Give it a name, like ‘AI’ and click ‘Add Binding’.
Now return to the worker editor and click “Edit Code”.
Replace the default code with the custom image generation API code from here.
After pasting the code, deploy the worker again.
Next, open the “Settings” tab of the worker and go to “Variables and Secrets”.
Create a new secret variable named:
API_KEY
Set any secret value you want. This will be used by Aimogen Pro to authenticate requests to your worker. But be sure to remember what you entered here.
Once done, open your deployed worker URL from the browser. It should look similar to:
https://your-worker-name.your-subdomain.workers.dev
Copy this URL.
Now go to your Aimogen Pro dashboard inside WordPress and open the AI Images settings section.
Set in plugin’s ‘Settings’ -> ‘API Keys’ tab:
- Cloudflare Worker URL -> your Worker URL
- Cloudflare Worker Secret -> the secret value you created earlier
Save settings.
That’s it. Aimogen Pro can now generate AI images using your own free Cloudflare Workers AI endpoint.











