Skip to content
masterclass Buddy

Arcjet · Concept

Next.js

Arcjet protects Next.js requests with configurable security rules. Create one SDK instance, call protect in a route, and allow or deny the request from the returned decision.

Last updated

Syntax

const aj = arcjet({ key: process.env.ARCJET_KEY, rules: [rule] });
const decision = await aj.protect(req);

In-depth API docs are only for subscribers: parameters, examples, common mistakes and interview practice.

Subscribe
  • shield
  • tokenBucket
  • fixedWindow
  • detectBot
  • protect
  • characteristics
  • proxies
  • cloudflare

Source: Arcjet Next.js SDK reference | Arcjet Docs. Checked 2026-11-03.