Sin impuesto Con impuesto

How to debug a 500 error or a blank page in PrestaShop

A blank screen gives no clues, but it always leaves a trace. This is the order in which we look for the cause when a store goes down.

Jesús Meilán
Updated: 26/09/2026 129
How to debug a 500 error or a blank page in PrestaShop
Share:

Few things are scarier than opening your store and seeing a blank page or a terse “500 Internal Server Error”. The good news: the cause is almost always written down somewhere. This is the order in which we look for it.

1. What has changed?

Before touching anything: has a module been installed or updated? Has the hosting’s PHP version changed? Has any file been uploaded? 80% of outages coincide with a recent change. If there is one, you already have your first suspect.

2. Enable debug mode (carefully)

In config/defines.inc.php:

define('_PS_MODE_DEV_', true);

With debug mode on, PrestaShop shows the full error on screen instead of an empty page. Only do it for as long as strictly necessary: the message can reveal server paths to any visitor. If you can, reproduce it on a copy of the store rather than in production.

3. Read the logs

  • var/logs/: the PrestaShop and Symfony logs (prod-AAAA-MM-DD.log). Look for CRITICAL and ERROR.
  • The hosting’s PHP error log (in cPanel it is usually under Metrics > Errors or in an error_log in the root).
  • The web server log, if the page does not even reach PHP.
grep -E "CRITICAL|ERROR" var/logs/prod-$(date +%F).log | tail -20

4. Rule out modules and overrides

In Advanced Parameters > Performance you can temporarily disable non-PrestaShop modules and overrides. If the store comes back, the cause is in one of them: re-enable them in halves until you find it.

If you cannot get into the back office, do it in the database: the active column of the module table is not enough; what decides whether a module runs is its row in module_shop.

5. Clear the cache, but properly

Delete the contents of var/cache/prod and var/cache/dev, not the whole var/cache folder: in some versions it holds a parameters file that PrestaShop needs to start.

6. “Blank with 200” pages

These are the most treacherous: the server responds fine but there is no content. The causes we see most:

  • A module or a PHP-level firewall that cuts the request short with exit.
  • A function that does not exist in the server’s PHP. For example, generating AVIF thumbnails when the GD library has no support for that format.
  • Memory exhausted while generating a very heavy page.

Here it helps a lot to run the page from the command line with an auto_prepend_file that logs, at shutdown, the last files loaded: it tells you exactly where it stopped.

7. Once you have it

Fix it, disable debug mode, clear the cache and write down what happened. The next time it occurs, someone will solve it in five minutes instead of an afternoon.

Loading...
Cookie consent
Back to top