xref: /aosp_15_r20/external/curl/docs/cmdline-opts/max-redirs.md (revision 6236dae45794135f37c4eb022389c904c8b0090d)
1---
2c: Copyright (C) Daniel Stenberg, <[email protected]>, et al.
3SPDX-License-Identifier: curl
4Long: max-redirs
5Arg: <num>
6Help: Maximum number of redirects allowed
7Protocols: HTTP
8Category: http
9Added: 7.5
10Multi: single
11See-also:
12  - location
13Example:
14  - --max-redirs 3 --location $URL
15---
16
17# `--max-redirs`
18
19Set maximum number of redirections to follow. When --location is used, to
20prevent curl from following too many redirects, by default, the limit is
21set to 50 redirects. Set this option to -1 to make it unlimited.
22