PrestaShop debug mode and logs: where to read the error message
You turn on PrestaShop debug mode under Advanced Parameters > Performance or in the config/defines.inc.php file. It fixes nothing by itself. It shows the error message instead of a blank page. Before you turn it on, look at the log under Advanced Parameters > Logs. The error message is often already there, with a date and the module name.
Author: The TellMyShop team. A guide for PrestaShop store owners: the cause, the manual fix and the same work in a chat conversation.
Last updated: · 5 min read
Where does PrestaShop record the error message?
In four places, and each one sees slightly different errors.
| Place | Where to find it | What it holds | When to look |
|---|---|---|---|
| PrestaShop log | Advanced Parameters > Logs | PrestaShop and module entries with a date and severity level | always, first |
| Debug mode | Advanced Parameters > Performance or config/defines.inc.php | the full message with file and line, right on the page | when the page is blank or shows a 500 error |
| Log files on the server | the var/logs folder | errors written by the Symfony layer | when the admin doesn't work or the error concerns the back office |
| Hosting error log | hosting panel, usually “error log” or “PHP logs” | PHP errors, including those PrestaShop did not manage to save | when the log in the admin is empty |
There is a fifth place too, the browser console. You open it with F12. It shows script errors, for example when a button does nothing and the shop logs are empty. You will find a description of the logs screen in the PrestaShop documentation.
How do you turn on debug mode safely?
For as short a time as possible, ideally on a test copy of the shop.
- Check the log. If the error message is already there, you don't need debug mode.
- Turn on debugging in the admin. Advanced Parameters > Performance, the debug mode switch. This page is described in the performance documentation.
- When the admin doesn't work, use the file. In
config/defines.inc.phpchange_PS_MODE_DEV_fromfalsetotrue. The developer documentation describes this. - Reproduce the error. Open the page that breaks and copy the whole message: the text, the file and the line number.
- Turn debugging off. Straight after copying the message. Debug mode shows technical details to every visitor.
- Clear the cache. Advanced Parameters > Performance, the button in the top right corner.
More switches, including turning off overrides and non-PrestaShop modules for the duration of a test, are described in icomSEO's guide to debug mode (in Polish).
How do you read a log entry?
Look at three things: the severity level, the file path and the date of the first occurrence.
The severity level tells you how urgent it is. One is information, two a warning, three an error and four a major issue that usually stops the page. The file path tells you whose error it is. A fragment like modules/module_name points to a module, themes/ to the theme and override/ to an override left by a module. The first occurrence date tells you what changed at that time. An error that started a quarter of an hour after a module update usually comes from that module.
Copy the entry in full when you send it to the module author or a developer. Add the PrestaShop version, the PHP version and a description of what you click before the error appears. When the shop already shows a 500 error, move to the plan in the article PrestaShop error 500. When the log points to a module, see how to disable a PrestaShop module without losing its data.
Which messages will you see most often?
A few kinds of messages keep coming back in PrestaShop shops, and each one hints at who to ask for help.
| Message fragment | What it usually means | Who can help |
|---|---|---|
| Allowed memory size exhausted | the script needed more memory than the server allows | your host |
| Class not found | a class file is missing, often after removing a module or with an old override | a developer |
| Undefined array key or Undefined index | the module is not adapted to a newer PHP, usually a warning | the module author |
| SQLSTATE | a database query error, often from a module | the module author or a developer |
| Unable to load template | a template file is missing in the theme or a module | the theme author or a developer |
Paste the message in full into your report. Don't shorten or paraphrase it, because the author searches for the exact text.
How do you review the log with the chat?
You ask for entries from a chosen period, and your chat (Claude or ChatGPT) groups repeated errors and explains them in plain language. It also names the module the error most likely points to.
You: Pull the errors and major issues from the log since Monday, group them by message and tell me which module they point to.
Your chat: Since Monday there are 52 entries at error level and no major issues. Three groups:
41 entries from the reviews module, always on the product page, since Tuesday morning.
9 entries from the newsletter module when an address is signed up, spread over time.
2 entries about a missing image in the Lanterns category, a minor content issue.
The first group is the most urgent. It started after the reviews module was updated.
Debug mode is off, and it should stay that way.
Reading the log works in the free TellMyShop Free, with no purchase. By default it covers the last 7 days and up to 200 entries at a time. Email addresses, phone numbers and IP addresses are masked. The technical review of the shop will also tell you if someone left debug mode on. You will find a ready request in the use case understand error messages after a module update.
The chat does not read files from the var/logs folder or the hosting error log. When the shop doesn't respond at all, the TellMyShop module doesn't work either, because it runs inside the shop.
Questions and answers
Where are the logs in PrestaShop?
In three places. The log in the admin is under Advanced Parameters > Logs and shows entries saved by PrestaShop and modules. Log files sit in the var/logs folder on the server. PHP errors that PrestaShop did not manage to save are in the error log in your hosting panel.
Can I leave debug mode on?
Don't leave it on. Debug mode shows technical details to every visitor, including file paths on the server. It also turns off part of the cache, so the shop runs slower. Turn it on for the diagnosis, ideally on a test copy, and turn it off straight afterwards.
What do the severity levels in the PrestaShop log mean?
Entries have four levels. One is information, two is a warning, three is an error and four is a major issue that usually stops the page. Day to day, look at levels three and four. Read warnings when something behaves oddly and the log has no errors.
How do I get error notifications by email?
Under Advanced Parameters > Logs you set the minimum severity level from which PrestaShop emails the administrator. Set it to errors or major issues, so three or four. At the warning level your inbox fills up fast and the important messages get lost among the minor ones.
Will the chat read the server logs?
The chat reads the PrestaShop log from the admin, by default for the last 7 days and up to 200 entries at a time. Email addresses, phone numbers and IP addresses are masked in the results. The chat does not read files from var/logs or the hosting error log. Check those in your hosting panel or ask your host for them.
PrestaShop is a registered trademark of PrestaShop SA. Claude is a trademark of Anthropic PBC. ChatGPT and OpenAI are trademarks of OpenAI. TellMyShop is not affiliated with these companies.