Debug logs not working for Site Guest Users ( sites) after the Winter 17 release [duplicate]

Recently our team has noticed that turning on the Debug Logs for a Site Guest User has stopped working. Prior to the Winter 17 release, if you turned on Debug Logs for a Site Guest User, logs appear like they do for any other user.

I couldn’t find any relevant information in Google on this topic, and finally got an answer from Salesforce Tech support, so I am posting it here.


The answer we received from Salesforce Tech support is that before the Winter 17 release, if you turned on debugging for a Site Guest User, you might receive an avalanche of debug logs if many different people were accessing your site at the same time.

After the Winter 17 release, you now also need to set a server cookie in the browser to enable debug logs for Site Guest Users. This means that debug logs will only be generated for those doing the debugging, not everyone accessing the site. This is true for sandboxes also.

An easy way to set this cookie in Chrome is to use the Javascript developer console. First, be sure your Chrome settings are set to “Allow local data” and “Allow both first-party and third-party cookies”.

Next, navigate to the site page that you want to debug. Open the Javascript console and enter the following (note that you need the “.” at the beginning of ‘’)


If you look in Chrome’s Cookie settings you should now see a ‘debug_logs’ cookie, and so the next time you reload your page, debug logs should re-appear again.

There is more documentation on Debug Logs here, but at the time of this writing, adding the cookie is not documented:

Salesforce: Set up Debug Logging

Source : Link , Question Author : Jph108 , Answer Author : Jph108

Leave a Comment