How to Create a Remote Control in Home Assistant

Sometimes you just can’t find that remote control, why not have it in your home assistant app too?

I’m using a HACS custom card called LG Web OS Remote Control that enables me to control my LG TV seamlessly.

I’m really impressed by the performance of this device and it was a breeze to install.


Once you have installed the HACS, home assistant community store, go to frontend, add repositories, search for LG Web OS Remote Control and add it in.

Now go to a dashboard and add /hacsfiles/LG-WebOS-Remote-Control/lg-remote-control.js to the resources.

To get to resources, 3 dots edit dashboards and add it in there.

Adding LG TV into home assistant

Go to configuration.yaml and add the code below, replace the host with the IP address of your LG TV (good idea to keep it on a fixed IP). MAC address is also unique and you will find it with the IP address on your router.

Feel free to change the list in the sources, to the APPS that you use.

  name: LG TV
    service: wake_on_lan.send_magic_packet
      mac: 78:5d:c8:54:62:1f
      - All 4
      - Amazon Prime Video
      - BBC iPlayer
      - Disney+
      - HDMI1
      - HDMI2
      - HDMI3
      - ITV Hub
      - My5
      - Netflix
      - Plex
      - WWE
      - YouTube

After restarting home assistant, you should find in the developer tool: media_player.lg_tv.


Below I created a little grid card with mini-media-player and custom:lg-remote-control

Feel free to adjust the colours, names, etc.

type: grid
  - type: custom:mini-media-player
    entity: media_player.lg_tv
    volume_stateless: false
    toggle_power: false
    sound_mode: icon
      volume: true
      power: true
      info: false
      source: true
      icon: true
      icon_state: true
      next: true
      prev: true
    group: true
    source: icon
    artwork: material
  - type: custom:lg-remote-control
    entity: media_player.lg_tv
      buttons: var(--deactive-background-button-color)
      texts: black
      background: rgba(1,77,122)
    color_buttons: BLUE
square: false
columns: 1


Gio loves rabbits, smart home tech, WWII, travelling to Thailand & my favourite pizza is margherita with parma ham!

Recent Posts