Skip to content
This is an unmaintained snapshot of the Astro v4 docs. View the latest docs.

Astro.clientAddress is not available in static mode.

StaticClientAddressNotAvailable: Astro.clientAddress is only available when using output: 'server' or output: 'hybrid'. Update your Astro config if you need SSR features.

The Astro.clientAddress property is only available when Server-side rendering is enabled.

To get the user’s IP address in static mode, different APIs such as Ipify can be used in a Client-side script or it may be possible to get the user’s IP using a serverless function hosted on your hosting provider.

See Also:

Contribute

What’s on your mind?

Create GitHub Issue

Quickest way to alert our team of a problem.

Community