Custom Component: Flightradar24

Yes, I agree.

I would like to see an example for a scheduled plane by flight number as I would like to track a few planes on a daily basis but dont want to do all flights from origin airport.

Also, is there a way to see all tracked flight numbers added as I may have added a couple of wrong ones, if it stores them ?

Thanks

For example, you may call service like I post above to start tracking a plane by flight number

...
      - service: text.set_value
        data:
          value: "{{ pass here flight number to track  }}"
        target:
          entity_id: text.flightradar24_add_to_track

To see all tracked flights numbers

    card:
      type: markdown
      content: >-
        {% set data = state_attr('sensor.flightradar24_additional_tracked',
        'flights') %} {% for flight in data %}
          {{ flight.flight_number }}
          {% endfor %}

@steve1123 @Dharmil Have you tried tracking scheduled flight feature yeat?

@AlexandrErohin …Thank you for your reply . For some reason Flightradar24 has banned my ip so I am trying to get it to work again .the add on just says unavailable since the ip is banned.

“ Hello

Thank you for contacting us.

Usually an IP is blocked when high data usage/scraping is detected on our site.
Any data available via Flightradar24.com is solely for servicing our website and is not intended for third parties
Please note that our terms and conditions of use can be referenced here and we will block any unauthorized attempts to access data from Flightradar24.com for other purposes.”

My plug in integration refresh time was set to 10 seconds and radius 100metres since I only needed tracking for particular flights . I wonder why did they ban my ip.

Hi,
What was the code for the sensor.flights_above_hourly ?
I am new to Home Assistant so i understand it goes in the config file?
Thanks

How to get rid of the flightradar24 branding and the app store icons.
Left is how the instructions left me, the right is how I tweaked it.

Hope this makes your dashboards a bit nicer

Create an html page in the www folder and remember the name. I used fr1.html
Replace the flightradar link with your lat/long/zoom link

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>FlightRadar</title>
    <style>
        html, body {
            margin: 0;
            padding: 0;
            height: 100%;
            overflow: hidden; /* Prevent scrolling in the body */
        }
        .iframe-container {
            position: relative;
            width: 100%;
            height: 500px; /* Adjust the height as needed */
            overflow: hidden; /* Ensure no scrollbars appear */
        }
        .iframe-container iframe {
            position: absolute;
            top: -100px; /* Adjust the top position to crop the top part */
            left: 0;
            width: 100%;
            height: 700px; /* Adjust this height to ensure the bottom part is also cropped */
            border: none;
        }
    </style>
</head>
<body>
    <div class="iframe-container">
        <iframe src="https://www.flightradar24.com/simple?lat=33.34&lon=-111.70&z=13&label1=reg&size=small"></iframe>
    </div>
</body>
</html>


Use the webpage card or add this code to your stacked cards

type: iframe
url: /local/fr1.html
aspect_ratio: 100%

13 Likes

How do I add additional tracked? Is add to track the same as the filter by callsign in the flightradar website?
I try to add a single and list of tracked items but it just stays at 0

Is there a relevant log in Settings->System->Logs?

Log showed that the tracked plane wasn’t found.
I guess aircraft can only be tracked and added when the are actively transmitting their beacon.

This error originated from a custom integration.

Logger: custom_components.flightradar24
Source: custom_components/flightradar24/coordinator.py:74
integration: Flightradar24 (documentation, issues)
First occurred: July 17, 2024 at 3:02:30 PM (9 occurrences)
Last logged: July 17, 2024 at 10:56:22 PM

FlightRadar24: No flight found by - HAWK
FlightRadar24: No flight found by - GM766
FlightRadar24: No flight found by - XX219
FlightRadar24: No flight found by - PT-ZNG
FlightRadar24: No flight found by - GAF858

Some of these arrived now.

I am near an airshow and was hoping to get alerted when certain planes enter airspace or take off for display
Screenshot 2024-07-18 143941

HAWK, GM766, XX219 - cannot be found FlightRadar search on their site. So why integration cannot add them

Hello,
I have the same issue, it seems I am not able to find any flights no matter what, departed or scheduled. I am talking about the “Add to track” function.
Could you please assist?

Also, is there a possibility to generate incremental graphs and/or autmatically export the flights into a google spreadsheet to keep a record?

Much appreciated, thanks.

i’m trying to do the same thing actually, have you got it working? you have gotten further than i have. I have just made a template sensor that extracts the flight number from my email but i’m at the same part you are in getting it to send it over to add to tracked flights

Hi, I like this alot. the app works nicely,
But, with the filght overview i get the error: 'TypeError: ‘NoneType’ object is not iterable"
Some knows how i can get it working?

I was able to add additional tracked planes in an automation, doesn’t really provide anything of use though, I guess I misunderstood the function of additional_tracked. I thought it was a way to predefine a list of planes I want to look out for, but they only can be added and only exist while they are visible on fr24.

I now have an automation which sends me a whatsapp image and detail of any of the plane types in my list entering my airspace. so I can see when something of interest is flying overhead or about to.

Would be great if multiple zones could be defined. Would also be good to define multiple/other sources.

Great work!
Any way of getting the age of the aircraft?

Can anybody help me with the format of the YAML?

I was able to set the google sheet integration and automation from sensor.flightradar24_current_in_area but I’d like to store some information like flight number, airline name, departure and arrival airports etc… I know the fields to call but I don’t know the exact format in order to call them.

Thanks to whoever will help, much appreciated.

EDIT:
Found the correct formatting for whoever is interested:
Flight Number: " {% set data = state_attr(‘sensor.flightradar24_current_in_area’, ‘flights’) %}{% for flight in data %}{{ flight.flight_number }}{% endfor %}"

Is it possible to use a device location ie phone instead of the fixed coordinates?

Hi @AlexandrErohin, my apologies for not getting back to you sooner. I didn’t get the message notification.

Yes! The tracking scheduled flight feature has been working great! That’s exactly what I was looking for and it has been working well. Thank-you for adding this great feature!

1 Like

I tried something similar recently. I was able to keep tabs on flights while on a long layover, which was a lifesaver for planning my next move. Having a system that shows all flights in the area and lets you track specific ones is incredibly handy. If you’re looking for a sweet deal on a flight, you might want to keep an eye out for some discount business class ticket. They really can make a huge difference on longer trips.

1 Like

@AlexandrErohin , can you give me a helping hand ?
I´m able to see the map, but it shows de flight number and not the call sign!
what I´m doing wrong ?!

"type: vertical-stack
title: Radar
cards: