SEO + AEO on AutopilotFrom the team at Stackmatix
The Growth Library

Check Critical HTML Against a Documented Crawler Byte Budget

Measure complete critical-block UTF-8 byte placement against a configurable illustrative budget while preserving current Googlebot-specific limits and source-unit caveats.

Check a large public response against the relevant consumer’s documented retrieval limit before assuming every downloaded byte is considered. A browser can obtain an intact document while a crawler stops earlier. That is different from transport truncation or an invalid compression stream.

The response integrity guide checks whether the intended representation arrived completely. This procedure measures where essential material appears in an uncompressed source response and keeps the consumer-specific limit separate from the checker’s own configured budget.

The worked threshold below is a deliberately fictional 128-byte engineering fixture. It is not Google’s limit and does not simulate Google’s renderer, index or canonical selection. Its purpose is to make byte-offset mistakes reproducible at a small scale.

Use the current main documentation with its exact scope

The inspected Googlebot main documentation says that when crawling for Google Search, Googlebot crawls the first 2 MB of a supported file type and the first 64 MB of a PDF. Referenced resources such as CSS and JavaScript are fetched separately under the stated non-PDF limit. The limit applies to uncompressed data.

The crawler infrastructure overview separately describes a default 15 MB limit with project- and file-type-specific exceptions, and explicitly gives Googlebot’s smaller limit as an example. Do not replace the Search-specific rule with the infrastructure default.

The Googlebot page’s embedded summary still says 15 MB while its substantive main section states 2 MB and 64 MB. Preserve that observed inconsistency and cite the main guidance. This review establishes current wording, not when a change happened. The inspected passages say MB without establishing a decimal-versus-binary conversion, so the fixture does not invent an exact Google byte count.

Measure the complete block,not just its first character

For the local test, the critical material is a complete section containing approved setup steps. Its start and end offsets are measured in UTF-8 source bytes, with an end-exclusive convention. A block beginning before the budget but ending after it is not fully contained.

The late case uses one hundred accented characters before the section. Their byte length differs from their character count. This catches a checker that measures decoded string positions while calling the result a byte offset.

The three fully specified source documents share the same head, critical section and closing markup. Only the padding changes. They remain ordinary complete fixture documents when read in full;the bounded prefix is a measurement artifact, not a replacement page to publish.

Run the complete offline placement check

The following standard-library code creates all three inputs and checks their declared placement. It opens no network connection and makes no statement about an actual crawler visit.

import gzip

budget = 128  # Fictional engineering fixture, NOT a Google byte threshold.
head = b'<!doctype html><html><head><title>Fixture</title></head><body>'
critical = b'<section id="key">Approved setup steps.</section>'
tail = b'</body></html>'
bodies = {
    'early': head + b' ' * 4 + critical + tail,
    'late': head + ('é' * 100).encode('utf-8') + critical + tail,
    'straddling': head + b' ' * (budget - len(head) - len(critical) // 2) + critical + tail
}
for name, body in bodies.items():
    start = body.index(critical)
    end = start + len(critical)  # End-exclusive byte offset.
    contained = critical in body[:budget]
    assert contained == (end <= budget)
    assert contained == (name == 'early')
    print(name, len(body), start, end, contained)
assert bodies['late'].index(critical) != len(bodies['late'].decode('utf-8').split('<section')[0])
print('gzip transfer size:', len(gzip.compress(bodies['late'], mtime=0)))
print('uncompressed source size:', len(bodies['late']))

The compression sizes printed at the end are separate observations about the synthetic file. They are not the quantity to compare with a documented uncompressed-data boundary. Preserve both dimensions instead of treating a small wire payload as proof that all source content falls within the relevant uncompressed budget.

Use the populated expected offsets

The expected results from the specified construction are:

CaseFull bytesStartEnd, exclusiveComplete section within 128 bytes
early12966115Yes
late325262311No
straddling167104153No

The straddling case is the important negative:a start-position-only assertion would approve it even though the complete section crosses the configured boundary. The late case detects a different error:using character count can understate the position after multibyte text.

These computed numbers belong only to the printed fixture. A real publisher must measure its actual generated response and select a justified engineering budget. Keep that configured threshold named and versioned rather than silently equating it with an undocumented exact provider byte conversion.

Inspect generated source before choosing a repair

Collect the actual ordinary response through an authorized public fetch and identify content encoding and source bytes. A source template’s character count is insufficient if rendering adds a large navigation tree, embedded data or repeated markup before the essential explanation.

The repair may be removing unnecessary duplication, changing what the initial response contains or splitting genuinely distinct resources. It should preserve the reader’s task. Do not move every sentence earlier while leaving an oversized, unmaintainable page or create thin pages solely to satisfy a number.

Use the rendered evidence method to distinguish initial source from later DOM content. A local prefix check cannot establish what another system renders or indexes. For shared templates, the regression contract can keep the measured critical-block placement inspectable after releases.

Close with a named consumer and a bounded result

The receipt should identify the current primary passage, consumer and file type, actual source encoding, configured engineering threshold, critical block, start/end convention and full-versus-prefix result. Keep referenced assets as separate resources under the documented scope rather than summing every file into one unsupported page budget.

Approve the local checker when its early, late and straddling cases behave as specified. Approve a real implementation only against the actual generated response and agreed publication contract. Preserve untested routes and unknown consumer behavior explicitly.

The result is evidence about source placement within a declared budget. It does not guarantee that being below a limit causes indexing, or that a complete HTTP response means every consumer processes every byte.

Sources

Matt Pru

Co-founder and CEO of Stackmatix. Writing about growth, customer acquisition, and the decisions behind useful marketing. Connect on LinkedIn.

Developed with AI assistance under Matt's editorial direction. Our Editorial Approach