---
title: geo.getLevel() function
description: geo.getLevel() returns the S2 cell level of specified cell ID token.
url: https://docs.influxdata.com/flux/v0/stdlib/experimental/geo/getlevel/
estimated_tokens: 167
product: Flux
version: v0
publisher: InfluxData
canonical: https://docs.influxdata.com/flux/v0/stdlib/experimental/geo/getlevel/
date: '2024-04-08T16:01:02-06:00'
lastmod: '2024-04-08T16:01:02-06:00'
---

* Flux 0.63.0+

InfluxDB support

> [!Important]
> `geo.getLevel()` is experimental and [subject to change at any time](/flux/v0/stdlib/experimental/#experimental-packages-are-subject-to-change).

`geo.getLevel()` returns the S2 cell level of specified cell ID token.

##### Function type signature

```js
(token: string) => int
```

For more information, see [Function type signatures](/flux/v0/function-type-signatures/).

## Parameters

### token

(Required)
S2 cell ID token.

## Examples

### Return the S2 cell level of an S2 cell ID token

```
import "experimental/geo"

geo.getLevel(token: "166b59")// Returns 10

```

[geotemporal](/flux/v0/tags/geotemporal/)
