Skip to content

Glossary: Next.js Beyond the Basics

Proxy

Also written: proxy.ts

A function in proxy.ts that Next.js runs before every matching request, before any page or action. It can redirect, rewrite or add headers, and was once called middleware.

Where the book teaches it

Related terms

Middlewareconfig.matcherOptimistic check