---
title: geo
summary: Package geo provides access to the geographic data for IP addresses.
url: https://www.fastly.com/documentation/reference/compute/sdks/go/compute-sdk-go/geo/
---

**Kind:** Module  
**Package:** compute-sdk-go v1.11.0  
**Path:** `github.com/fastly/compute-sdk-go/geo`

Package geo provides access to the geographic data for IP addresses.

## Structs

| Name | Summary |
| --- | --- |
| [Geo](https://www.fastly.com/documentation/reference/compute/sdks/go/compute-sdk-go/geo/struct.Geo/) | Geo represents the geographic data for an IP address. |

## Functions

| Name | Summary |
| --- | --- |
| [Lookup](https://www.fastly.com/documentation/reference/compute/sdks/go/compute-sdk-go/geo/fn.Lookup/) | Lookup returns the geographic data associated with a particular IP address. |

## Variables

### ErrInvalidIP

**Type:** `error`  
**Default:** `errors.New("geo: invalid IP")`  
**Source:** https://github.com/fastly/compute-sdk-go/blob/d6bf71b04516ed72d6018cab6fff701a865f86e5/geo/geodata.go#L16

ErrInvalidIP indicates the input IP was invalid.

### ErrUnexpected

**Type:** `error`  
**Default:** `errors.New("geo: unexpected error")`  
**Source:** https://github.com/fastly/compute-sdk-go/blob/d6bf71b04516ed72d6018cab6fff701a865f86e5/geo/geodata.go#L19

ErrUnexpected indicates an unexpected error occurred.
