Zillow API for Home Assistant

Zillow home value in Home Assistant

Keep your home's Zillow Zestimate in Home Assistant next to everything else you track: one sensor or one automation, refreshed weekly or monthly, with no browser or scraper to maintain.

Base URL https://api.propertiesapi.com/v1 · auth header x-api-key. PropertiesAPI is an independent service that returns Zillow property and listing data as JSON, provided as-is.

How Home Assistant fits

Home Assistant used to ship a Zestimate sensor. It called GetZestimate in Zillow's old web services API, and when Zillow retired that API the sensor was removed, so a configuration that still names it no longer works. Fetching the Zillow page from Home Assistant instead is fragile: Zillow's pages sit behind bot detection, and requests from a home server are often blocked or shown a captcha. Home Assistant's built-in REST integration can call PropertiesAPI instead: one GET request with your key in the x-api-key header returns the Zestimate shown on the home's public Zillow page as JSON.

Look the home up by its zpid, the number before _zpid in its Zillow link, the same id the old sensor used. A zpid always names the same property, so every refresh updates the same home. The Zestimate is Zillow's estimate, returned when Zillow shows one; it is not an appraisal, and PropertiesAPI is not affiliated with Zillow.

Keeping one home current uses one lookup per refresh: 12 lookups a year on a monthly schedule, 52 on a weekly one. On the free plan, a monthly refresh of one home uses the 50 free lookups you start with, then 1 of the 10 free lookups each month, so it stays free with no end date. Repeat lookups of the same home within 24 hours come from our cache and are free. Failed lookups cost nothing. A live lookup takes typically 6 seconds, up to about 20 seconds. That upper end is longer than Home Assistant waits by default, so both recipes below set a longer timeout.

Put the key in secrets.yaml

Home Assistant reads !secret values from secrets.yaml, next to configuration.yaml, so the key stays out of any configuration you share or back up to a public repository.

secrets.yaml
propertiesapi_key: "your_key_here"

The quick way: a REST sensor that refreshes weekly

Add this to configuration.yaml and restart. The availability template marks the sensor unavailable, instead of storing a wrong number, when Zillow shows no Zestimate, the lookup was refused, or the response carries a warning. A warning in meta.warning can say the home returned may not be the one you asked for, or that billing for the lookup could not be confirmed; the recipe skips any warned value to be safe, and the next poll tries again. The REST integration also looks the home up each time Home Assistant starts; if you restart often, use the monthly automation instead.

configuration.yaml
rest:
  - resource: https://api.propertiesapi.com/v1/zillow/property
    params:
      zpid: "15073305"        # your home's zpid, from its Zillow link
    headers:
      x-api-key: !secret propertiesapi_key
    timeout: 130                    # seconds; the default of 10 is shorter than a slow live lookup
    scan_interval: 604800           # once a week, in seconds
    sensor:
      - name: Home Zestimate
        unique_id: home_zestimate
        value_template: "{{ value_json.data.zestimate }}"
        availability: >-
          {{ value_json is defined and value_json.data is defined
             and value_json.data.zestimate is number
             and value_json.meta.warning is not defined }}
        device_class: monetary
        unit_of_measurement: USD
        state_class: total
        json_attributes_path: "$.data"
        json_attributes:
          - rentZestimate
          - homeStatus
          - detailUrl

The exact way: a monthly automation

rest_command makes the request only when the automation runs, so restarts cost nothing, and an input_number keeps the last value across restarts. The automation runs early on the first day of each month and writes the value only when the lookup succeeded, Zillow showed a Zestimate and the response carries no warning. Otherwise it keeps the last value and posts a notification with the reason, including when no response arrived in time: continue_on_error lets the automation go on after a timeout or network error instead of stopping.

configuration.yaml and automations.yaml
# configuration.yaml
rest_command:
  zillow_home_value:
    url: "https://api.propertiesapi.com/v1/zillow/property?zpid=15073305"
    headers:
      x-api-key: !secret propertiesapi_key
    timeout: 130

input_number:
  home_zestimate:
    name: Home Zestimate
    min: 0
    max: 100000000
    step: 1
    mode: box
    unit_of_measurement: USD

# automations.yaml
- alias: Refresh home Zestimate monthly
  triggers:
    - trigger: time
      at: "03:00:00"
  conditions:
    - condition: template
      value_template: "{{ now().day == 1 }}"
  actions:
    - action: rest_command.zillow_home_value
      response_variable: lookup
      continue_on_error: true       # a timeout or network error leaves lookup unset instead of stopping
    - if:
        - condition: template
          value_template: >-
            {{ lookup is defined
               and lookup.status == 200
               and lookup.content.data.zestimate is number
               and lookup.content.meta.warning is not defined }}
      then:
        - action: input_number.set_value
          target:
            entity_id: input_number.home_zestimate
          data:
            value: "{{ lookup.content.data.zestimate }}"
      else:
        - action: persistent_notification.create
          data:
            title: Home Zestimate not updated
            message: >-
              {% if lookup is not defined %}No response in time, or PropertiesAPI could not be reached. The next run tries again.
              {% elif lookup.content.error is defined %}{{ lookup.content.error.code }}: {{ lookup.content.error.message }}
              {% elif lookup.status != 200 %}HTTP status {{ lookup.status }}
              {% elif lookup.content.meta.warning is defined %}{{ lookup.content.meta.warning }}
              {% else %}Zillow shows no Zestimate for this home right now.{% endif %}

Home Assistant gotchas

  • Keep the timeout line. Home Assistant's default timeout is shorter than the slowest live lookups, so without it a slow lookup fails.
  • Don't shorten scan_interval for fresher numbers. Within the cache window a poll returns the same collection, and after it every poll is a new lookup that uses a credit.
  • A refused lookup, for example when your lookups run out, leaves the REST sensor unavailable until its next scheduled poll. To retry sooner, run the homeassistant.update_entity action on the sensor.
  • The automation's first value arrives on the first of the month. To fill it now, open the automation and choose Run actions, which skips the trigger and the condition.
  • Zillow doesn't show a Zestimate for every home. Both recipes treat a missing estimate as no update, never as zero, so a net worth total built on them doesn't suddenly drop.

Zillow API and Home Assistant: questions

What happened to the Zestimate sensor in Home Assistant?+

It called GetZestimate in Zillow's old web services API with a ZWSID key. Zillow retired that API, and the integration was removed from Home Assistant. The REST sensor on this page takes its place and uses the same zpid.

Can I use the address instead of the zpid?+

Yes: put address in params instead of zpid, or address= in the rest_command URL with the address URL-encoded. Each refresh then matches the address to a Zillow property again, so the zpid is the safer choice for a value you track.

Can I get the rent Zestimate too?+

Yes, from the same lookup. The REST sensor already stores rentZestimate as an attribute. For a sensor of its own, add a second entry under sensor with a value template that reads value_json.data.rentZestimate; sensors under one resource share one request.

Can I track more than one home?+

Yes. Add one REST block or one rest_command per zpid. Each home is its own lookup on each refresh.

What does it cost?+

Zillow links and addresses cost the same: 1 credit per successful lookup. Repeat lookups of the same home within 24 hours come from our cache and are free. You start with 50 free lookups.

Make your first call from Home Assistant

50 lookups to start, then 10 free every month, no card, no approval.

Zillow is a trademark of Zillow, Inc. PropertiesAPI is an independent service and is not affiliated with, endorsed by or sponsored by Zillow.