[wp-trac] [WordPress Trac] #64364: There has been a critical error on this website.
WordPress Trac
noreply at wordpress.org
Mon Dec 8 07:06:53 UTC 2025
#64364: There has been a critical error on this website.
--------------------------+------------------------------
Reporter: dandavince | Owner: (none)
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: General | Version:
Severity: normal | Resolution:
Keywords: | Focuses:
--------------------------+------------------------------
Comment (by aarti1318):
@dandavince I understand the need to avoid exposing technical details
publicly, and fully agree that the current screen exists to protect
sensitive information for non-technical site owners.
However, I think there is a middle ground that improves the user
experience without compromising security.
My suggested direction:
* Continue showing the generic “There has been a critical error” message
by default.
* Add a non-JS <details> debug section only visible to logged-in
administrators, even when WP_DEBUG is false.
* The section could include:
* the error message (sanitized)
* the file + approximate line
* a short suggestion like “This is most likely caused by plugin: X” if
detected from the stack trace
* For visitors, nothing changes — they still only see the generic safe
error page.
* For recovery mode, the enhanced information would integrate with the
existing “broken plugin” identification logic.
This keeps technical info secure + only accessible to admins, while
finally reducing the frustration of having to enable debug mode (which
many users don’t know how to do or don’t have file access for).
This would make the critical error screen both safer and more useful, and
aligns with the idea that the site owner should get actionable information
without needing hosting-level access.
I’m happy to work on testing or refining this approach if the core team is
interested.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/64364#comment:3>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list