# Body (Bytes)
Sometimes you need to handle raw data that doesn't fit neatly into JSON or Forms—like webhooks, custom binary protocols, or raw text. For this, you use the web::Bytes extractor.
#Extracting Bytes
Using web::Bytes loads the entire request body into memory.
code_blocksrust
use actix_web::{post, web, HttpResponse};
#[post("/webhook")]
async fn webhook(body: web::Bytes) -> HttpResponse {
println!("Received {} bytes", body.len());
HttpResponse::Ok().finish()
}#Streaming the Body
If you expect very large payloads, loading everything into memory (Bytes) can cause OOM errors. Instead, you can extract the web::Payload and process it as an asynchronous stream of byte chunks.