> ## 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.

# ST_GeomFromBox2D (Python)

> Convert a Box2D to a Geometry.

Convert a Box2D to a Geometry.

Dispatches on dimensionality (matching PostGIS box2d::geometry and
Sedona's ST\_Envelope): POINT for 0-D boxes, LINESTRING for 1-D boxes,
POLYGON otherwise. NULL on null input.

SQL reference: [`ST_GeomFromBox2D`](/reference/wherobots-db/geometry-data/box2d/ST_GeomFromBox2D)

## Signature

```python theme={"system"}
from sedona.spark.sql.st_constructors import ST_GeomFromBox2D

ST_GeomFromBox2D(box: ColumnOrName) -> Column
```

## Parameters

<ParamField path="box" type="ColumnOrName" required>
  Box2D column to convert.
</ParamField>

## Returns

<ResponseField name="return" type="Column">
  Geometry column.
</ResponseField>


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