Broken Resources Detected by Real Users
Broken resources, in the context of Real User Monitoring (RUM), are files (images, JavaScript, CSS and other files) that fail to load correctly for your real website visitors. These errors can significantly degrade user experience and negatively impact your website's performance.
Types of Broken Resources
PerfBee's RUM feature reports files that an element of your page failed to load, such as:
- Images: Missing or incorrectly linked image files.
- Scripts: JavaScript files that fail to load, potentially breaking functionality.
- Stylesheets: CSS files that fail to load, leading to incorrect styling.
- Fonts: Font files loaded by a
<link>element, such as a preloaded font, that fail to load, causing fallback fonts and impacting design consistency.
Files requested from inside a stylesheet, such as background images and @font-face fonts, do not raise an error on an element, so the RUM script cannot see them.
How PerfBee Detects Broken Resources
PerfBee's RUM implementation uses a lightweight JavaScript snippet installed on your website. This snippet listens for the browser's error events: when an element such as an image, script or stylesheet fails to load its file, it records the file's URL. Each page view reports up to 20 failed files, sent with the page's other measurements when the visitor leaves the page. This allows PerfBee to identify resources that are failing to load for your real users.
Broken Resources List
Within the RUM dashboard, the Broken Resources card lists, for each broken resource:
- URL: The path of the broken resource. Hover over it to see the full URL.
- Hits: The number of page views in which the resource failed to load.
The card shows the 20 most frequent failures. Failures from common ad and analytics services, such as Google Analytics, Google Tag Manager, DoubleClick, Facebook, Hotjar, Microsoft Clarity, Criteo and Amazon ads, are left out. The list is filled when "Last 7 days" is selected; the 30-day and 90-day views do not include it.
Why Broken Resources Matter
Broken resources cause a poor user experience. Missing images, broken layouts, and non-functional features frustrate users and can lead to higher bounce rates and lower conversion rates. Broken resources also impact performance by preventing the browser from rendering the page correctly, leading to slower page load times and lower Core Web Vitals scores like Largest Contentful Paint (LCP).
How to Fix Broken Resources
Addressing broken resources is crucial for improving user experience and performance. Here's how to fix them:
- Identify the Broken Resource: Use the PerfBee RUM dashboard to identify the specific URLs of broken resources.
- Verify the URL: Double-check the URL for typos or incorrect file paths.
- Update the URL: If the resource has moved or the URL is incorrect, update the link in your website's code.
- Remove the Resource: If the resource is no longer needed, remove the link from your website.
- Test the Fix: After making changes, revisit the RUM dashboard to confirm the issue is resolved.
Difference from Site Crawler Broken Link Detection
While the PerfBee Site Crawler also detects broken links, RUM provides a different perspective. The Site Crawler requests your pages as PerfBeeBot and checks the links and files it finds on them. RUM, however, detects broken resources encountered by *real* users. This is crucial for catching issues that might only appear under specific conditions (e.g., after a CDN change or asset deletion) or for specific user segments. The RUM data can complement the Site Crawler data to give a full picture of your website’s resource health.
For more information, see the PerfBee Documentation.