Images aren’t being generated
If your post published successfully but the featured image or body images didn’t appear, work through this page in order. The most common cause lives in Step 1 — it’s an environment issue rather than anything wrong with your campaign.
Before you start
Open Tools → Site Health in WordPress. Structura adds three probes there that light up when the most common image-generation blockers are present:
- MySQL packet size is sufficient for background tasks
- WordPress cron is enabled
- WordPress uploads directory is writable
If any of those are flagged red or yellow, fix that first — the steps below spell out each fix.
Step 1: Is MySQL’s max_allowed_packet too small?
This is the single most common cause we see on shared hosting.
What’s happening. Structura queues image-generation jobs using
Action Scheduler , which stores each
queued job in the wp_actionscheduler_actions table. If the serialized
job data is larger than MySQL’s max_allowed_packet setting, the
database silently rejects the row. No PHP error, no error in the admin.
The job is simply never created — so the image never generates.
Structura 1.17+ catches this at enqueue time and logs an error in
Structura → System Logs with the step VISUALS. The message looks
like:
Featured image task could not be enqueued. Action Scheduler refused the write — this is usually a MySQL packet-size limit (max_allowed_packet) or a database-write failure on wp_actionscheduler_actions.
How to fix it. You need to raise max_allowed_packet to at least
4 MB (4194304). How you do that depends on your host:
- Shared hosting (Hostinger, SiteGround, Bluehost, etc.) — open a
support ticket asking them to raise
max_allowed_packeton your database to 4 MB or larger. Most hosts will do this within a few hours; it’s a common request. - Managed WordPress (Kinsta, WP Engine, Pressable) — your host has already set a reasonable value. If Site Health still flags this, open a support ticket and include a screenshot of the Site Health card.
- VPS / self-managed — add
max_allowed_packet = 16Munder[mysqld]in/etc/mysql/my.cnf(or the equivalent on your MySQL / MariaDB install) and restart the database service.
After the change takes effect, run a campaign again or click Generate image on any Structura-generated post’s edit screen — the image should now save correctly.
Step 2: Is WordPress cron disabled?
What’s happening. If your wp-config.php includes
define('DISABLE_WP_CRON', true); and there’s no system cron hitting
wp-cron.php, background image-generation jobs are queued but never run.
How to fix it. Either:
- Remove the
DISABLE_WP_CRONconstant fromwp-config.php, or - Add a server-side cron that calls
wp-cron.phpevery minute:
* * * * * wget -q -O - https://your-site.com/wp-cron.php?doing_wp_cron >/dev/null 2>&1Most managed hosts handle this for you. On shared hosting you may need to set the cron job yourself in your hosting panel.
Step 3: Is the uploads directory writable?
What’s happening. Generated images are imported via WordPress’s
media_handle_sideload() helper, which writes to
wp-content/uploads/YYYY/MM/. If that directory (or its parent) isn’t
writable by PHP, the sideload fails. Site Health surfaces the exact
WordPress error message.
How to fix it. Make the uploads directory writable by the web server. The typical fix on Linux hosts:
chown -R www-data:www-data wp-content/uploads
chmod -R 755 wp-content/uploadsAdjust the user (www-data, apache, nobody, etc.) to match your
host’s web server user.
Step 4: Is the image provider configured correctly?
If none of the environment checks above flagged an issue, the problem may be provider-side.
- Open Structura → Settings → AI Engine.
- Confirm your Image provider is connected (green check).
- If you’re on the Free or Pro plan (BYOK), confirm the provider you selected is image-capable. Claude produces text only — if you selected Claude for images, Structura will skip image generation silently on BYOK plans (on managed plans we substitute an image-capable provider automatically).
See AI settings for a full tour.
Step 5: Still stuck?
Open Structura → System Logs and filter to Step = VISUALS and Level = Error or Warning. The log line usually names the exact failure — copy the message into a support ticket along with:
- Your plan tier
- Your configured image provider
- The campaign name
- A screenshot of Tools → Site Health