Skip to main content

googlewifiapi

An asynchronous Python client for reading status from the local JSON API exposed by Google Wifi routers. The package is designed for integrations such as Home Assistant, but can be used by any Python application that needs router status data.

About this README

This README was generated by AI with human review. All code is either written by a human or is thoroughly reviewed. I'll try to keep the README updated, but sometimes I might forget.

Requirements

  • Python 3.13 or newer
  • A Google Wifi router reachable on the local network

Installation

pip install googlewifiapi

Usage

Pass an aiohttp.ClientSession to the client so your application controls the session lifecycle:

import asyncio

import aiohttp

from googlewifiapi import GoogleWifiAPI


async def main() -> None:
    async with aiohttp.ClientSession() as session:
        router = GoogleWifiAPI(host="192.168.86.1", sess=session)
        await router.async_update()

        if router.data is not None:
            print(router.data.wan.online)
            print(router.data.software.software_version)
            print(router.data.system.last_restart)


asyncio.run(main())

The host defaults to 192.168.86.1. After a successful update:

  • router.raw_data contains the raw JSON response.
  • router.data contains a validated, typed GoogleWifiStatus.
  • IP address fields are parsed as IPv4Address or IPv6Address objects.
  • system.last_restart is calculated from the router's uptime.

The status object exposes dns, software, system, and wan sections. Their fields use Python names such as software_version, gateway_ip_address, and ip_prefix_length, while the client handles the router API's camelCase keys.

Errors

All library errors inherit from GoogleWifiException:

  • GoogleWifiClientError indicates a request, connection, timeout, or JSON decoding failure.
  • GoogleWifiDataValidationError indicates that the response does not match the expected status schema.

Development

Install the test dependencies and run the test suite with uv:

uv sync --group test
uv run pytest

License

This project is licensed under the MIT License. See LICENSE.txt.

Disclaimer

This is an independent, community-developed project and is not affiliated with or endorsed by Google LLC. It relies on a local API that Google may change or remove without notice.

Release files for googlewifiapi 0.1.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for googlewifiapi 0.1.0
File Size Uploaded
googlewifiapi-0.1.0.tar.gz 6.3 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for googlewifiapi 0.1.0
File Interpreter ABI Platform
googlewifiapi-0.1.0-py3-none-any.whl Python 3 none any Details

Total release size: 12.3 kB

Release files / googlewifiapi-0.1.0.tar.gz

Download URL googlewifiapi-0.1.0.tar.gz
Size 6.3 kB
Tags Source
SHA-256 checksum
How to use checksums
9fe8ef9c503a1bcd17beb8725fdaa599ac44c796b8fe895316d6c9b12b8d90a1
BLAKE2b-256 checksum
How to use checksums
9b196d1875107e4e80338ab538e85789d15f4b91e5c8812c79f2afdc902ffd43
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 25, 2026.

Transparency log

Release files / googlewifiapi-0.1.0-py3-none-any.whl

Download URL googlewifiapi-0.1.0-py3-none-any.whl
Size 6.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
a8bb152cfd422ca3fac2683a5c8378563498b4005720dea496c7f7b5668a865b
BLAKE2b-256 checksum
How to use checksums
443855211888ef20421ef7b848bf3a1ab0c37c5d7ed69ad66e97a8314a075708
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 25, 2026.

Transparency log

Release history Release notifications | RSS feed

This release

0.1.0 This release

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page