> For the complete documentation index, see [llms.txt](https://docs.glesys.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.glesys.com/products/connectivity/load-balancer/how-tos/view-statistics.md).

# View statistics

There are statistics available for the load balancer.

***

## View statistics using the control panel

Under the **Statistics** tab, you can view the number of connections to the load balancer in a graph. The maximum number of connections you set is also displayed as a red line.

<figure><img src="https://3379166260-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FlMZhhdQNcWOpX5Bj48GK%2Fuploads%2Fuu7zV1wW09EbLH0tWiUp%2Fload-balancer-statistics.png?alt=media&amp;token=c4ec7591-dec0-4c32-89ac-cde1307cea42" alt=""><figcaption></figcaption></figure>

## View statistics using the API

It's possible to extract the current number of connections and the maximum number of allowed connections using the [API](/platform/control-panel/api.md). Use the [loadbalancer/details](https://github.com/GleSYS/API-docs/wiki/API-Documentation#loadbalancerdetails) endpoint to extract the information. The key `currentsessions` contains the number of current connections, and `maxconnections` contains the maximum number of allowed connections.

For example, by using cURL you can extract all the data in XML format:

{% code title="Command" %}

```
curl -s -X POST --data-urlencode "loadbalancerid=lb1234567" -k --basic -u CL123456:KEY https://api.glesys.com/loadbalancer/details/
```

{% endcode %}

Or, if you prefer JSON format:

{% code title="Command" %}

```
curl -s -X POST --data-urlencode "loadbalancerid=lb1234567" -k --basic -u CL123456:KEY https://api.glesys.com/loadbalancer/details/format/json
```

{% endcode %}

You can then use `jq` to select the first load balancer's `currentsessions`.

```
curl -s -X POST --data-urlencode "loadbalancerid=lb1234567" -k --basic -u CL123456:KEY https://api.glesys.com/loadbalancer/details/format/json | jq '.response.loadbalancer.frontends[0].currentsessions'
```
