> ## Documentation Index
> Fetch the complete documentation index at: https://docs.wherobots.com/llms.txt
> Use this file to discover all available pages before exploring further.

# GeoSeries.length

> Returns a Series containing the length of each geometry in the GeoSeries.

Returns a Series containing the length of each geometry in the GeoSeries.

In the case of a (Multi)Polygon it measures the length of its exterior (i.e. perimeter).

For a GeometryCollection it measures sums the values for each of the individual geometries.

## Signature

```python theme={"system"}
GeoSeries.length: pspd.Series
```

## Returns

<ResponseField name="return" type="Series">
  A Series containing the length of each geometry.
</ResponseField>

## Examples

```python theme={"system"}
>>> from shapely.geometry import Polygon
>>> from sedona.spark.geopandas import GeoSeries
```

```python theme={"system"}
>>> gs = GeoSeries([Point(0, 0), LineString([(0, 0), (1, 1)]), Polygon([(0, 0), (1, 0), (1, 1)]), GeometryCollection([Point(0, 0), LineString([(0, 0), (1, 1)]), Polygon([(0, 0), (1, 0), (1, 1)])])])
>>> gs.length
0    0.000000
1    1.414214
2    3.414214
3    4.828427
dtype: float64
```


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.