In the front-end monitoring, the loading time of cross-domain images is all zero, which response header should be added

📅 October 12, 2026 👁️ 14

Why is the loading time of cross-domain images in the front-end monitoring all zero, and which response header should be added - the answer is the timing bypass header, which is forced to zero when it is missing. The official documentation is clear: this header specifies which sources are allowed to see the attribute values obtained through the resource timing interface, otherwise these values will be reported as zero due to cross-domain restrictions. The point is that 'zero reading' does not mean that the resource did not take any time, but rather that the client is prohibited from telling you how much time it took.

Zero time does not mean that the resource did not take any time.

The resource timing interface splits a single request into several stages: redirection, domain resolution, connection and negotiation, sending the request, waiting for the first byte, and receiving the content. When the page accesses images across domains, these details are not exposed by default, and the segmented timing returned by the interface is uniformly set to zero, leaving only a few unrestricted items. As a result, the monitoring panel will show a misleading conclusion: the image timing is not visible, and it is considered to have no timing. Any attribution work on this data will be distorted.

What is this header allowing?

The permission that is allowed is read permission, not access permission. Whether the resource can be loaded is determined by the source strategy and the reference in the page; this header only determines whether the script can see the detailed time information. This determines that the risk of modification is very low: after adding it, the original images can still be obtained in the same way, but the monitoring can be split into stages. Conversely, omitting it will not cause the image display to be abnormal, but will only cause data loss - such problems are often discovered only when someone looks at the time distribution carefully.

How to write the value, how to handle multiple sources

Two writing methods. One is wildcard, all sources can read the timing; the other is a comma-separated list of sources, only listing the page addresses that need to read the data. The choice is very direct: if the monitoring collection end address is fixed and known, write a list; if the site is embedded by multiple parties or the source is difficult to enumerate, consider wildcard. Note that this header must appear in the response on the resource side, not on the domain where the page is located - images are on another domain, so the domain must return.

Phenomenon Reasons for data Where to change How to confirm after changing
Cross-domain image segment timing is zero Unreleased timing read count Response of the domain where the image is located Resample and check if there are any non-zero values in each stage
Self-image has data, image service does not Only released in the main domain Image service or cache layer Reproduce once by bypassing the cache and directly connecting to the source station
Unable to read after adding the header The front-end layer filters out the header Cache layer that generates the response Compare direct connection and response after caching twice
Suddenly unable to read after going online New response header definition at the same level inherits Server configuration level position Check if there are other header addition instructions written at this level

Before attribution, confirm what the collection end can read

Before adding the header, it is worth checking the collection口径 first. The script on the page reads which indicator, whether it includes cross-domain attributes, and whether it distinguishes between same-origin and cross-domain when reporting, these three things determine whether you can see the numbers you want after adding the header. There is also an easily overlooked factor in the internal image link: the title automatically assigns images to the article, and after adding watermarks, the image address is often different from the page address. The images of this kind in AnQiCMS take an independent path and static resources, and when cross-domain timing is not allowed, it is the easiest to read as zero in the monitoring.

Don't treat it as performance optimization itself.

This header solves the visibility issue. After completion, there will be no change in the page loading speed, but you can see for the first time where the slow-down is: negotiation, waiting for the first byte, or receiving content. This step is very crucial for content sites, and the official criteria for page loading speed is significantly improved compared to traditional PHP programs, with a single machine capable of handling about 5 million PV. These descriptions refer to the server-side capabilities and do not mean that there are no bottlenecks in the specific page resource chain. When it comes to optimization, the only input that can be used is segmented data.

Common questions

What are the risks of wildcard writing? Answer: It exposes the time details rather than the content, the risk is not big, but it will provide site resource distribution information to scripts from any source, and if you can collect a list, collect a list.

What if you can't change the response of the third-party service for images? Answer: You can only add the service address to the exceptions of the collection口径, or change it to be reverse-proxied by your own domain, and add this header at the reverse proxy layer.

Is it enough to only supplement the image domain? Answer: Scripts, fonts, and stylesheets are also subject to this restriction, and any cross-domain resources that require segmented and time-consuming processing must be allowed in their respective responses.

Related articles

The intermediate response code for pre-loading resources on the first screen, why is it only issued in multi-path multiplexing protocols in most cases?

The 103 intermediate response used for pre-loading resources on the first screen is a prompt issued by the server before it organizes the final page, allowing the client to pre-connect or pre-load resources. The official documentation suggests that for compatibility and security reasons, it should only be sent in HTTP protocol version 2 or higher, as most browsers only support it under these conditions. The reason is that under old protocols, the boundary handling between intermediate responses and final responses is inconsistent, which is easy to confuse with the content of waiting responses.

2026-10-12

How to check the status code conditions and inheritance level when the security response header is added but not present in some responses?

The security response header is added but not visible in some responses, usually stuck at two places: first, the header addition instruction only takes effect for specific response codes, the effective codes listed in the mainstream Web server documentation include two hundred successful segments and three hundred redirects, non-successful responses need to be added unconditionally with the always parameter; second, the hierarchical inheritance rule - once the header addition instruction is defined at the same level, the entire set of definitions at the upper level no longer inherits. The troubleshooting sequence is to first reproduce the response code missing the header, and then locate which level of configuration generates it.

2026-10-12

After splitting search and training into two switches, the access rules should be judged according to which purpose

On September 15, 2026, an edge platform announcement divided search, AI training, and AI agents into three independent controls, so the site does not have to choose between retaining search and blocking training. The announcement also provided two ratios: the mixed-purpose crawler accounted for 36.6% of the verified crawling traffic, less than 1% of the site side would block search crawlers, and about 17% restricted AI training. After the switches are opened, the access rules should be judged according to the purpose of access, not according to the source domain.

2026-10-12

There is a measurement that says the scraping scripts only follow a part of the exclusion rules, where is the difference in the ratio

A measurement covering thirty-six institutional sites, forty days of traffic, and about one hundred and thirty self-reported identity scraping scripts shows that the compliance rate varies greatly by instruction type: about 60.9% for scraping frequency instructions, about 31% for precise path prohibition, and about 30.7% for whole section prohibition; and less than four in ten scripts will re-read the exclusion file within one hundred and sixty-eight hours. These numbers indicate that relying solely on the exclusion file is not sufficient, and there must also be anti-crawling and permission layers within the site.

2026-10-12

What is the situation when the login credentials are partitioned by the top-level site when embedded by other sites?

Login credentials with partition attributes are stored separately by the top-level site: one is read when the same address is accessed directly, and another is read when the page is embedded by other sites, and they do not share. The official document states that this attribute indicates that credentials should be stored using partitioned storage, and it must be set at the same time as the security mark, and it is recommended to bind the credentials to the host with a hostname prefix name instead of a registrable domain. If the site assumes that the login state is globally shared, it will not be read in the embedded scenario.

2026-10-12

Why does the program overwrite the entire site configuration file when saving settings, and why does it overwrite the rules I added myself?

When saving settings, the program overwrites the directory-level configuration file, taking away the manually added rules along with it, because these files are only one copy, generated in full by the program according to its own template. The same program PbootCMS has fixed this issue in the update record of V3.2.26: When Apache turns on pseudo-static, it misjudges the environment, causing the configuration file under the site directory to be overwritten every time it is saved. The approach is to separate the rules managed by the program from the rules added by operations and maintain them in two places, backup before modification, and compare item by item after modification.

2026-10-12

The explicit specification of an index in a list query is actually slower, in what situations will it degrade to a full table scan?

Writing a fixed index hint in a list query is equivalent to letting the optimizer give up the opportunity to choose a path based on statistical information: when the hint points to an index that does not match the current conditions, the query that could have used a covering index or range scan will be pushed to a more costly execution method, and further degraded into a full table scan when the conditions fail. The same program PbootCMS has fixed the issue of list tags degrading to a full table scan due to index hints in the update records of V3.2.26, and has unified the new libraries to be indexed by the title field.

2026-10-12

Why should the database script in the online upgrade be arranged in version order, and what should be done if it fails halfway

The database script for the online upgrade must be executed strictly in the order of version numbers, as each script is based on the premise that 'the previous one has been completed': the new field has not been created, and the next one will fail when writing values. Skipping intermediate versions during cross-version upgrade will leave the table structure halfway. If the script fails halfway, the safe approach is to stop immediately and leave a log, rather than ignoring the error and continuing to run the remaining scripts, otherwise the problem will be covered by the subsequent scripts. Make a backup of data and static files before the upgrade, and check each section after the upgrade.

2026-10-12