home-assistant

Setting Up Aqara Motion Sensor P1 with Home Assistant

Complete guide to pairing and configuring the Aqara Motion Sensor P1 in Home Assistant via ZHA or Zigbee2MQTT.

Prerequisites

  • Home Assistant 2024.1 or later installed and running
  • Zigbee coordinator (e.g., SONOFF Zigbee Dongle Plus-E or SkyConnect)
  • ZHA or Zigbee2MQTT integration configured
  • Aqara Motion Sensor P1 with battery inserted

Step 1: Prepare Your Zigbee Network

Ensure your Zigbee coordinator is connected and recognized by Home Assistant. Navigate to Settings > Devices & Services and confirm your ZHA or Zigbee2MQTT integration is online.

Step 2: Put the Sensor in Pairing Mode

Press and hold the reset button on the bottom of the Aqara Motion Sensor P1 for 5 seconds until the blue LED starts flashing. The sensor is now in pairing mode for approximately 3 minutes.

Step 3: Add the Device

Using ZHA

  1. Go to Settings > Devices & Services > ZHA
  2. Click Add Device
  3. The sensor should appear as “Aqara Motion Sensor” within 30 seconds
  4. Click to confirm the pairing

Using Zigbee2MQTT

  1. Open Zigbee2MQTT web interface
  2. Click Permit Join in the top bar
  3. The sensor will appear in the device list once paired
  4. Rename it to something descriptive like “Living Room Motion”

Step 4: Configure Sensitivity

The Aqara Motion Sensor P1 supports three sensitivity levels (low, medium, high). In Home Assistant:

  1. Go to Settings > Devices > Aqara Motion Sensor P1
  2. Under Configuration, find the sensitivity setting
  3. Adjust to your preferred level

Step 5: Create Automations

automation:
  - alias: "Turn on lights on motion"
    trigger:
      - platform: state
        entity_id: binary_sensor.living_room_motion
        to: "on"
    action:
      - service: light.turn_on
        target:
          entity_id: light.living_room

Troubleshooting

Sensor not detected during pairing: Make sure you are within 3 meters of the coordinator and that the battery is fresh. Try resetting by holding the button for 10 seconds.

Motion detection seems delayed: The default re-trigger time is 60 seconds. This is a hardware limitation. Consider using the occupancy duration setting in Zigbee2MQTT if available.

Sensor shows unavailable after a while: Check that you have enough Zigbee router devices (smart plugs, switches) to maintain mesh coverage to the sensor location.