Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/esphome/esphome.io/llms.txt

Use this file to discover all available pages before exploring further.

The remote_receiver component lets your ESP device listen for infrared (IR) and RF remote control signals on a GPIO pin and decode them into known protocols — NEC, Sony, Samsung, RC5, RC6, Panasonic, Pioneer, and dozens more. Once decoded, signals can trigger automations directly or be matched by binary sensors that momentarily activate when a specific code is received.

Minimal Example

remote_receiver:
  pin:
    number: GPIO18
    inverted: true
    mode:
      input: true
      pullup: true
  dump: all
With dump: all, every received code appears in the ESPHome logs at DEBUG level. Use this to discover the protocol and address/command values of any remote.

Configuration Variables

pin
Pin
required
The GPIO pin connected to the data output of your IR or RF receiver module (e.g. TSOP38238, SRX882).
dump
list or 'all'
Protocols to decode and print in the logs. Set to all to enable every available decoder. Individual options include: nec, samsung, sony, rc5, rc6, panasonic, pioneer, lg, jvc, aeha, raw, pronto, rc_switch, coolix, haier, midea, toshiba_ac, nexa, keeloq, dyson, dooya, drayton, and many more.
tolerance
int or Time or mapping
Acceptable deviation in signal timing. Defaults to 25%. Can be expressed as a percentage or a fixed time value. For noisy RF signals, try increasing to 50% or 60%.
filter
Time
Ignore pulses shorter than this duration. Removes glitches from noisy signals. Defaults to 50us.
idle
Time
Time a signal must remain stable before it is considered complete. Defaults to 10ms. On ESP32 with RMT hardware, maximum is 65536us (at default clock resolution).
buffer_size
int
Internal buffer for received codes. Defaults to 10kB on ESP32 and 1kB on ESP8266.
id
ID
Manually specify the component ID. Required when multiple receivers are configured.

ESP32 RMT Options

rmt_symbols
int
RMT memory allocated to this component (multiples of block size). Controls DMA buffer size when use_dma is enabled.
clock_resolution
int
RMT peripheral clock in Hz. Defaults to 1000000 (1 MHz = 1 µs resolution).
use_dma
boolean
Enable DMA mode on supported ESP32 variants for large buffer sizes.
filter_symbols
int
Filter out received data shorter than this many RMT symbols.

Automation Triggers

Each supported protocol has a corresponding on_<protocol> trigger. The decoded data is passed as variable x.
remote_receiver:
  pin: GPIO18
  dump: all
  on_nec:
    then:
      - lambda: |-
          ESP_LOGI("remote", "NEC address=0x%04X command=0x%04X",
            x.address, x.command);
  on_samsung:
    then:
      - if:
          condition:
            lambda: "return x.data == 0xE0E040BF;"  # volume up
          then:
            - media_player.volume_up: my_player
Available triggers: on_nec, on_samsung, on_samsung36, on_sony, on_rc5, on_rc6, on_panasonic, on_pioneer, on_lg, on_jvc, on_aeha, on_coolix, on_haier, on_midea, on_toshiba_ac, on_raw, on_pronto, on_rc_switch, on_nexa, on_keeloq, on_dyson, on_dooya, on_drayton, on_beo4, on_byronsx, on_canalsat, on_canalsatld, on_dish, on_gobox, on_magiquest, on_roomba, on_symphony, on_mirage, on_toto, on_abbwelcome.
Raw codes (on_raw) give you a list of pulse widths in microseconds (positive = ON, negative = OFF). You can copy this list directly into a remote_transmitter configuration to replay the signal.

Binary Sensor: Matching Specific Codes

Use binary_sensor with platform: remote_receiver to create entities that briefly activate when a specific remote code is detected.
binary_sensor:
  - platform: remote_receiver
    name: "TV Power Button"
    nec:
      address: 0x7F80
      command: 0x3FC0

  - platform: remote_receiver
    name: "AC Cool Mode"
    samsung:
      data: 0xE0E08877
      nbits: 32

  - platform: remote_receiver
    name: "RF Socket 1 ON"
    rc_switch_type_a:
      group: "01001"
      device: "10110"
      state: true
receiver_id
ID
Specify which receiver to use when multiple receivers are configured.

Supported Code Types for Binary Sensors

Each entry uses the same fields as the corresponding on_<protocol> trigger:
ProtocolKey Fields
necaddress, command
samsungdata, nbits (default 32)
sonydata, nbits (default 12)
rc5address, command
rc6address, command
panasonicaddress, command
pioneerrc_code_1
lgdata, nbits (default 28)
rawcode (list of int)
rc_switch_type_agroup, device, state
rc_switch_type_baddress, channel, state
rc_switch_rawcode (binary string)

Hardware Setup Tips

Many IR receiver modules (like the TSOP38238) have an active-low output. Use inverted: true and mode: {input: true, pullup: true} on the pin.
# Typical TSOP38238 / TSOP31238 configuration
remote_receiver:
  pin:
    number: GPIO18
    inverted: true
    mode:
      input: true
      pullup: true
  dump: all
  filter: 50us
  idle: 10ms
# RF 433 MHz receiver (no invert, no pullup)
remote_receiver:
  pin: GPIO21
  dump: rc_switch
  tolerance: 60%
  filter: 4us
  idle: 4ms
For the Sonoff RF Bridge, you can bypass the onboard EFM8BB1 co-processor with a hardware mod and use pin: 4 for RX and pin: 5 for TX with carrier_duty_percent: 100%.

Complete Example: TV Remote Control

remote_receiver:
  pin:
    number: GPIO18
    inverted: true
    mode:
      input: true
      pullup: true
  dump: nec

binary_sensor:
  - platform: remote_receiver
    name: "TV Volume Up"
    nec:
      address: 0x7F80
      command: 0x1CE3
    on_press:
      - media_player.volume_up: living_room_speaker

  - platform: remote_receiver
    name: "TV Volume Down"
    nec:
      address: 0x7F80
      command: 0x9C63
    on_press:
      - media_player.volume_down: living_room_speaker

  - platform: remote_receiver
    name: "TV Power"
    nec:
      address: 0x7F80
      command: 0x3FC0
    on_press:
      - switch.toggle: tv_power_relay

Build docs developers (and LLMs) love