Error: Maximum number of routes (rewrites, redirects, etc) exceeded. Max is 1024, received 1100. Please reduce the number of routes. : Limits
Turborepo 2.3.3, Nextjs 15.1.4
Error: Maximum number of routes (rewrites, redirects, etc) exceeded. Max is 1024, received 1100. Please reduce the number of routes. : Limits
Turborepo 2.3.3, Nextjs 15.1.4
As the error message suggests, you are hitting one of our limits for maximum number of routes. You can review next.config.js
which should contains redirects
or rewrites
and help you to understand the number of routes your application have. additionally, you may have few additional defined within:
redirect()
functionmiddleware.ts
We’d recommend reducing the number of redirects/rewrites or moving them over to Edge Middleware which doesn’t have this route limit. We have a guide which covers the different options and how to implement them here: How can I increase the limit of redirects or use dynamic redirects on Vercel?
In the first instance to get your site up and running, we’d recommend trying to remove unused redirects/rewrites or implementing regex for specific cases that would match certain patterns. Once that’s been done, you can then look at other options such as using Edge Middleware to handle these.
This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.