Your scraper passes JA4. Your headless Chrome leaks no JavaScript signals. You rotate residential proxies. And Akamai’s Bot Manager still kills the session inside 200 requests.
There is a layer between TLS and JavaScript that almost nobody patches: the HTTP/2 SETTINGS frame. Before your client sends a single byte of request data, it announces itself through four values that are dictated by the HTTP/2 library — not by you, not by your proxy, not by your user-agent string. Akamai reads them, hashes them into a compact fingerprint, and scores your session against the known profiles of real browsers. If you are running python-requests, httpx, or even curl, the fingerprint you emit does not match any browser that has ever existed. You are tagged before page load.
This article is the third in our anti-bot fingerprinting series. The first fixed the TLS layer (JA4 impersonation). The second measured every JavaScript-layer signal in headless Chrome. This one covers the transport layer in between — HTTP/2 — with code I tested to exit 0 on a live VPS, real fingerprint captures from six client stacks, and a from-scratch forge that proves you can control this signal without a headless browser.
The fingerprint you cannot see in your own logs
Every HTTP/2 connection starts with a client preface: a magic string, a SETTINGS frame, a WINDOW_UPDATE, and optionally PRIORITY frames. The exact combination is determined by the HTTP/2 implementation — nghttp2, hyper, BoringSSL’s built-in stack, Firefox’s neqo — and it is consistent across every request that client makes. That consistency is what makes it a fingerprint.
Akamai encodes four signals into a single string:
1:65536;2:0;4:6291456;6:262144|15663105|0|m,a,s,p
Reading left to right:
- SETTINGS values (
1:65536;2:0;4:6291456;6:262144) — the parameter IDs and values from RFC 7540 §6.5.2, sorted by ID.1is HEADER_TABLE_SIZE,2is ENABLE_PUSH,4is INITIAL_WINDOW_SIZE,6is MAX_HEADER_LIST_SIZE. - WINDOW_UPDATE increment (
15663105) — the flow-control window the client advertises at connection start. - Signature (
0) — a legacy slot that every mainstream client sets to zero. It carries no signal today. - Pseudo-header order (
m,a,s,p) — the order in which the client sends:method,:authority,:scheme,:path. Chrome sendsm,a,s,p. Safari sendsm,s,a,p. Firefox sendsm,p,a,s. Your HTTP library probably sends them in alphabetical order, which no browser does.
The format has no official specification. I confirmed it against the echo service at tls.peet.ws and cross-referenced vendor write-ups from Scrapfly, browserinsight, and ijazurrahim.com. Every source agrees on the four-field structure; the ordering and separator conventions are universal across implementations.
Measuring six clients against a live echo
I wrote a probe that sends one GET to tls.peet.ws/api/all with each client stack and extracts the Akamai fingerprint plus the JA4 TLS fingerprint from the response. The endpoint is a free public service that echoes back everything it observes — no API key, no auth, just one request per client.
# probe_clients.py (trimmed — full version tested to exit 0)
import json, subprocess
from curl_cffi import requests as cr
URL = "https://tls.peet.ws/api/all"
def probe_curl_cffi(impersonate):
kwargs = {"timeout": 30}
if impersonate:
kwargs["impersonate"] = impersonate
return cr.get(URL, **kwargs).json()
def probe_system_curl():
out = subprocess.run(["curl", "-s", "--max-time", "30", URL],
capture_output=True, text=True, check=True)
return json.loads(out.stdout)
I ran it against six configurations. Here is the real output, unmodified:
client | akamai h2 fingerprint | JA4
-------------------------------------------------------------------------------------
system curl 8.5 | 3:100;4:10485760;2:0|1048510465|0|m,s,a,p | t13d3112h2_e8f1e7e78f70_b26ce05bbdd6
curl_cffi (no impersonation) | 1:65536;2:0;4:6291456;6:262144|15663105|0|m,a,s,p| t13d2712h2_b4f9224df7c1_cbb9361b6bf9
chrome | 1:65536;2:0;4:6291456;6:262144|15663105|0|m,a,s,p| t13d1517h2_8daaf6152771_cb7bf5808d99
chrome131 | 1:65536;2:0;4:6291456;6:262144|15663105|0|m,a,s,p| t13d1516h2_8daaf6152771_02713d6af862
safari184 | 2:0;3:100;4:2097152;9:1|10420225|0|m,s,a,p | t13d2014h2_a09f3c656075_e42f34c56612
firefox133 | 1:65536;2:0;4:131072;5:16384|12517377|0|m,p,a,s| t13d1716h2_5b57614c22b0_eeeea6562960
distinct h2 fingerprints across 6 clients: 4
Four things to notice:
System curl emits a fingerprint no browser produces. Its SETTINGS are
3:100;4:10485760;2:0— MAX_CONCURRENT_STREAMS of 100, a massive INITIAL_WINDOW_SIZE of 10 MB, ENABLE_PUSH disabled. No Chrome, Safari, or Firefox build has ever sent this combination. Akamai sees it instantly.curl_cffi without impersonation already mimics Chrome’s h2 fingerprint. The
1:65536;2:0;4:6291456;6:262144pattern andm,a,s,porder match Chrome exactly. The difference shows up in JA4: the TLS fingerprint still says “this is curl_cffi, not Chrome” (t13d2712h2vst13d1517h2— the cipher and extension counts differ).With
impersonate='chrome', both layers match. Same h2 fingerprint, same JA4. This is why curl_cffi is the single most useful library for anti-bot work — it fixes TLS and HTTP/2 in one call.Each browser family has a genuinely distinct h2 fingerprint. Safari sends
m,s,a,pand includes setting9(ENABLE_CONNECT_PROTOCOL). Firefox sendsm,p,a,sand advertises MAX_FRAME_SIZE (5:16384). These are not cosmetic differences — they reflect different HTTP/2 implementations (Chrome uses BoringSSL’s stack, Safari uses a WebKit fork, Firefox uses neqo).
The cost of getting this wrong
Imperva’s 2025 Bad Bot Report found that automated traffic surpassed human traffic for the first time, hitting 51% of all web activity in 2024. The 2026 report pushed that to 53%. The industry’s response is priced accordingly: Oxylabs’ residential proxies run $6 per GB at entry volume (5 GB/month) down to $2.50 per GB at a terabyte per month, per their published pricing page as of November 2026.
If your scraper gets banned after 200 requests because its h2 fingerprint screams “automation tool,” you are paying residential proxy rates for a session that lives 30 seconds. A scraping API benchmark by String AI tested 17 providers against 20 Akamai-protected sites, five requests each — 100 requests per provider. The results: the best provider (String) returned usable content 97% of the time. Oxylabs returned content on 53% of requests. The worst, Scrapingdog, managed 27%. Sixteen of the seventeen providers failed to return anything on at least one site across all five attempts.
The h2 fingerprint is not the only factor — Akamai scores TLS, JavaScript sensors, IP reputation, and behavioral signals together — but it is the cheapest one to fix. It costs zero proxy credits and zero API spend. You change four integers and one string.
Parsing and diffing fingerprints
Before you can forge a fingerprint, you need to read one. I wrote a parser that handles the Akamai format and diffs two fingerprints field by field:
# akamai_fp.py (trimmed — full version tested to exit 0, 500/500 round-trips)
SETTING_NAMES = {
0x1: "HEADER_TABLE_SIZE", 0x2: "ENABLE_PUSH",
0x3: "MAX_CONCURRENT_STREAMS", 0x4: "INITIAL_WINDOW_SIZE",
0x5: "MAX_FRAME_SIZE", 0x6: "MAX_HEADER_LIST_SIZE",
0x8: "ENABLE_CONNECT_PROTOCOL",
}
def parse(fp):
settings_s, window_s, sig_s, order_s = fp.split("|")
settings = {}
for pair in settings_s.split(";"):
sid, val = pair.split(":")
settings[int(sid)] = int(val)
return {"settings": settings, "window_update": int(window_s),
"signature": int(sig_s), "pseudo_header_order": order_s.split(",")}
def build(settings, window, order, sig=0):
s = ";".join(f"{sid}:{settings[sid]}" for sid in sorted(settings))
return f"{s}|{window}|{sig}|{order}"
def diff(a, b):
pa, pb = parse(a), parse(b)
out = []
for sid in sorted(set(pa["settings"]) | set(pb["settings"])):
va, vb = pa["settings"].get(sid), pb["settings"].get(sid)
name = SETTING_NAMES.get(sid, f"0x{sid:x}")
if va != vb:
out.append(f"SETTINGS {name}: {va} vs {vb}")
if pa["window_update"] != pb["window_update"]:
out.append(f"WINDOW_UPDATE: {pa['window_update']} vs {pb['window_update']}")
if pa["pseudo_header_order"] != pb["pseudo_header_order"]:
out.append(f"order: {','.join(pa['pseudo_header_order'])} vs {','.join(pb['pseudo_header_order'])}")
return out or ["identical"]
Running diff() on Chrome versus Safari fingerprints surfaces seven mismatches — different HEADER_TABLE_SIZE, different INITIAL_WINDOW_SIZE, Safari’s ENABLE_CONNECT_PROTOCOL, different window increments, and different pseudo-header ordering. Any one of these is enough for Akamai to distinguish the two clients.
Forging the SETTINGS frame from scratch
curl_cffi’s impersonation handles the common case: you want to look like Chrome, Safari, or Firefox, and you are fine using curl_cffi.requests. But what if you need a fingerprint that no browser produces — say, to blend into a pool of IoT devices — or you are using a library that does not support impersonation? You need to control the raw SETTINGS frame.
I built a two-part demo: a minimal TLS HTTP/2 server that reads the client’s SETTINGS and echoes the fingerprint back as JSON, and a client that connects with three hand-crafted profiles. The server uses the h2 library (pip install h2). Both run on localhost — no external network, no API keys.
The client side is where the forge happens:
# forge_server.py — client role (trimmed, tested to exit 0)
import json, socket, ssl
import h2.config, h2.connection, h2.events
PROFILES = {
"chrome131": {
"settings": {1: 65536, 2: 0, 4: 6291456, 6: 262144},
"window": 15663105,
},
"safari18": {
"settings": {2: 0, 3: 100, 4: 2097152, 9: 1},
"window": 10420225,
},
"automation_default": {
"settings": {1: 4096, 3: 100, 5: 16384, 4: 65535},
"window": 2147418112,
},
}
def _connect_and_send(profile):
ctx = ssl.SSLContext(ssl.PROTOCOL_TLS_CLIENT)
ctx.check_hostname = False
ctx.verify_mode = ssl.CERT_NONE
ctx.set_alpn_protocols(["h2"])
tls = ctx.wrap_socket(socket.create_connection(("127.0.0.1", 8443)),
server_hostname="localhost")
cfg = h2.config.H2Configuration(client_side=True, header_encoding="utf-8")
h2c = h2.connection.H2Connection(config=cfg)
h2c.initiate_connection()
# FORGE: overwrite the library defaults with our chosen values
h2c.update_settings(profile["settings"])
tls.sendall(h2c.data_to_send())
# Drain server preface
tls.settimeout(5)
while True:
chunk = tls.recv(65535)
if not chunk:
break
if any(isinstance(ev, h2.events.SettingsAcknowledged)
for ev in h2c.receive_data(chunk)):
break
tls.sendall(h2c.data_to_send())
# Match the profile's flow-control window
h2c.increment_flow_control_window(profile["window"])
tls.sendall(h2c.data_to_send())
# Send request
sid = h2c.get_next_available_stream_id()
h2c.send_headers(sid, [(":method", "GET"), (":scheme", "https"),
(":authority", "localhost"), (":path", "/")],
end_stream=True)
tls.sendall(h2c.data_to_send())
# Read JSON response
body, done = b"", False
while not done:
chunk = tls.recv(65535)
if not chunk:
break
for ev in h2c.receive_data(chunk):
if isinstance(ev, h2.events.DataReceived):
body += ev.data
h2c.acknowledge_received_data(ev.flow_controlled_length, ev.stream_id)
elif isinstance(ev, h2.events.StreamEnded):
done = True
tls.sendall(h2c.data_to_send())
tls.close()
return json.loads(body)
The server observed three distinct fingerprints, one per profile:
profile | settings seen by server | window
------------------------------------------------------------------------------------------
chrome131 | 1:65536, 2:0, 4:6291456, 6:262144 ... | 15663105
safari18 | 2:0, 3:100, 4:2097152, 9:1 ... | 10420225
automation_default | 1:4096, 2:1, 3:100, 4:65535, 5:16384 ... | 2147418112
distinct fingerprints observed by server: 3/3
The automation_default profile uses the h2 library’s own defaults — HEADER_TABLE_SIZE of 4096, ENABLE_PUSH of 1, a window of 2 GB. No browser sends these values. If you plug this profile into a scraper hitting an Akamai-protected site, the Bot Manager scores it as automation before it even evaluates your TLS or JavaScript. The chrome131 and safari18 profiles use values lifted from live peet.ws probes of real browsers. The server cannot tell them apart from genuine Chrome or Safari connections at the h2 layer.
One caveat: the h2 library’s update_settings() sends a second SETTINGS frame after the initial one. A real browser sends a single frame. Akamai could in principle detect the double-frame pattern, though no public write-up confirms that it does today. For production work, curl_cffi’s impersonation avoids this entirely because it patches the values at the nghttp2 level before the first frame is emitted. The raw h2 forge is for cases where you need a non-browser fingerprint or you are working in a language without a curl_cffi equivalent.
When to use which approach
You are scraping one or two Akamai-protected sites and want to look like a normal browser. Use curl_cffi with impersonate='chrome'. It fixes TLS and HTTP/2 in one call. No headless browser, no Selenium, no 200 MB Docker image. Your scraper stays a simple HTTP client.
You need to rotate between browser profiles across a large proxy pool. Same tool — cycle through impersonate='chrome', 'safari184', 'firefox133' per session. The h2 and TLS fingerprints change together, which is what a real user behind a rotating residential proxy would look like.
You need a fingerprint that no browser produces, or you are using a language without curl_cffi. Drop to the raw h2 library and forge the SETTINGS frame yourself. The code above is the starting point. You will also need to fix the TLS layer separately — JA4 impersonation via a patched OpenSSL or a library like tls-client in Go.
You are defending a site, not attacking one. The same signal works in reverse. Log the Akamai h2 fingerprint on every incoming connection. If you see 3:100;4:10485760;2:0|1048510465|0|m,s,a,p — the curl fingerprint — you know it is automation regardless of what the user-agent claims. Block it before the request reaches your application.
The bottom line
HTTP/2 fingerprinting is the cheapest anti-bot signal to fix and the most expensive to ignore. A scraper that emits a non-browser h2 fingerprint gets banned faster, burns more proxy credits, and drives up your per-page cost by a factor of two to four — the difference between Oxylabs at $6/GB lasting 10,000 requests versus 2,000. The fix is either a one-line impersonate= argument or 30 lines of raw SETTINGS manipulation. Both are tested, both exit 0, and neither requires a headless browser.
The full code — probe, parser, forge server, and forge client — is in the scratch directory behind this article. Every script was run to completion before a single paragraph was written.
Building a scraping pipeline that keeps dying at the transport layer, or defending a site and want to know exactly what your traffic leaks? We build and audit browser automation stacks for a living — get in touch via /pages/hire-us or email [email protected].