Skip to main content

Generate pages in the background

Hand a big run to your server: close the tab while your pages generate, track progress in Manage, and cancel anytime.

Written by Niklas

This article covers Background Generation: how to hand a run to your server, follow it in Manage, and cancel it.

Normally LPagery creates your pages in the browser tab. You watch the progress bar and keep the tab open until it finishes. For a handful of pages that works fine. For hundreds or thousands it gets fragile, because a closed laptop, a lost connection or a closed tab interrupts the run.

With Background Generation your own WordPress server does the run instead. You confirm the run, close the tab, and the pages keep generating. You can follow the progress or cancel the run from Manage at any time.

Background Generation is available on the LPagery Extended plan and above.
Click here to purchase LPagery Pro ->

Browser generation stays the default. You choose per run.

1. Turn on "Generate in background"

Set up your pages as usual. On the confirm step, where you would normally click Create pages, you'll find a Generate in background toggle. Switch it on and confirm.

The toggle is off by default. If you use background runs all the time, you can make it your default in Settings.

2. Close the tab

As soon as the run is handed over, LPagery confirms it:

From this moment the run belongs to your server. You can close the tab or the laptop, and the pages keep generating.

3. Track progress in Manage

Open Manage in the LPagery dashboard. The page set's row shows a status badge that updates every few seconds while the run is active:

  • Queued: the run is accepted and waiting for the worker to pick it up, usually seconds.

  • Running (N of M): LPagery is creating the pages. N of M rows are done.

  • Completed: every row succeeded. Your pages are ready.

  • Completed with N failed: the run finished, but N rows failed. Click the badge to see which rows and why.

  • Cancelled: you cancelled the run.

  • Stalled: the run isn't progressing. See Troubleshooting below.

While any background run is active, a small indicator also appears in the LPagery header, wherever you are in the dashboard. Click it to jump to Manage.

4. Cancel a run

Open the menu on the page set in Manage and choose Cancel Background Run. The run stops, the remaining queue is discarded, and the set is free for a new run right away, in the background or in the browser. Pages that were already created stay.

Only one run can be active per page set. While a background run is active on a set, starting anything else on that same set is rejected with "A background run is already in progress for this Page Set. Cancel it before starting another." That covers another background run, a browser run, and a Google Sheet sync. Cancel is always the way out. Runs on different page sets are independent.

Where the toggle appears

Background Generation covers every heavy, data-driven run. You'll find the toggle when you create a new page set (the confirm step, as above) and when you update or re-upload a page set with new spreadsheet data (the same toggle on the update confirm step). When you switch the Render Mode of a whole set between Classic and Live, the switch dialog offers Switch in background.

The toggle does not appear for a preview page, because that is a single page and the browser is faster. It also doesn't appear when you only change the set's design or template, since template reassignment stays in the browser. Sets synced from Google Sheets or the LPagery App already run on the server, so they need no toggle.

Make Background Generation your default

In Settings you'll find Default background generation:

When it's on, the Generate in background toggle comes pre-selected on every create, update and switch. You can still turn it off for an individual run.

What happens to failed rows?

A background run never gives up on the whole job because of one bad row. LPagery retries a failing row a couple of times with increasing delays. If it still fails after 3 attempts, the row is skipped and the run moves on. At the end you get Completed with N failed. Click the badge to see exactly which rows failed and the error for each, fix the data, and run an update.

Troubleshooting

The run shows "Stalled"

Your WordPress server's task system (WP-Cron) executes background runs. On some hosts that system is disabled or can't reach your own site, so nothing ever picks the run up. If a run has waited around 10 minutes with no sign of the worker, LPagery flags it as Stalled instead of leaving it on "Queued" forever. You can cancel the run and generate in the browser instead, or ask your host to set up a real server cron job for WordPress. A real cron job also makes scheduled posts and sheet syncs more reliable.

"A background run is already in progress for this Page Set."

Only one operation can run per page set at a time. Either wait for the active run to finish (watch it in Manage) or cancel it via ⋯ -> Cancel Background Run, then start your new run.

"This site's server upload limit is too small for background generation."

Handing a run to the server means uploading your prepared page data to it in one go. LPagery checks your server's upload limit before sending anything and splits large runs into smaller chunks. If the host's limit is too small for even one chunk, you'll see this message before anything is uploaded. Use browser generation for that run, or ask your host to raise post_max_size.

The badge says "Completed with N failed"

The other rows succeeded. Click the badge to open the error details, fix the affected rows in your data, and run an update on the set.

Did this answer your question?