1---
2c: Copyright (C) Daniel Stenberg, <daniel.se>, et al.
3SPDX-License-Identifier: curl
4Title: CURLOPT_NOPROGRESS
5Section: 3
6Source: libcurl
7See-also:
8  - CURLOPT_DEBUGFUNCTION (3)
9  - CURLOPT_PROGRESSFUNCTION (3)
10  - CURLOPT_VERBOSE (3)
11  - CURLOPT_XFERINFOFUNCTION (3)
12---
13
14# NAME
15
16CURLOPT_NOPROGRESS - switch off the progress meter
17
18# SYNOPSIS
19
20~~~c
21#include <curl/curl.h>
22
23CURLcode curl_easy_setopt(CURL *handle, CURLOPT_NOPROGRESS, long onoff);
24~~~
25
26# DESCRIPTION
27
28If *onoff* is to 1, it tells the library to shut off the progress meter
29completely for requests done with this *handle*. It also prevents the
30CURLOPT_XFERINFOFUNCTION(3) or CURLOPT_PROGRESSFUNCTION(3) from
31getting called.
32
33# DEFAULT
34
351, meaning it normally runs without a progress meter.
36
37# PROTOCOLS
38
39All
40
41# EXAMPLE
42
43~~~c
44int main(void)
45{
46  CURL *curl = curl_easy_init();
47  if(curl) {
48    curl_easy_setopt(curl, CURLOPT_URL, "https://example.com");
49
50    /* enable progress meter */
51    curl_easy_setopt(curl, CURLOPT_NOPROGRESS, 0L);
52
53    /* Perform the request */
54    curl_easy_perform(curl);
55  }
56}
57~~~
58
59# AVAILABILITY
60
61Always
62
63# RETURN VALUE
64
65Returns CURLE_OK.
66