Traefik default route

Hi all,

How can I set "default routes" like redirect to www.somewhere.com which will be used in case no other routers have been selected?

Thank you,
AP

Use a route such as Path(`/`) or PathPrefix(`/`) combined with redirect regex middleware also set it to a very low priority (1) so it is evaluated after all other routes.

This has limited use with https unless you have a wildcard certificate as a TLS would occur before a request could be sent.

1 Like