--emulate-memory
- CLI
- --emulate-memory
- REST
- emulate_memory
Sets navigator.deviceMemory and the Device-Memory client hint, in GB, rounded as Chrome rounds it: the nearest power of two, from 2 to 32 on desktop and from 1 to 8 under an Android user agent. 0 removes both, as on iOS Safari.
Default
Without this flag the page sees the host’s RAM, rounded the same way: a 16 GB host reports 16, and reports 8 under an Android user agent. Under a Safari or Firefox user agent it sees undefined.
Example
zshot -f page.png \
--emulate-memory 8 \
https://zshot-cli.com/example_assets/zemu/{
"url": "https://zshot-cli.com/example_assets/zemu/",
"output_type": "png",
"emulate_memory": 8
}curl -X POST http://127.0.0.1:3000/ \
-H "Content-Type: application/json" \
-d '{"url":"https://zshot-cli.com/example_assets/zemu/","output_type":"png","emulate_memory":8}' \
-o page.png