Skip to content
Simple DSL monitoring tool for Fritz!Box 7430 in Python 3
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Type Name Latest commit message Commit time
Failed to load latest commit information.


A simple DSL monitoring tool for Fritz!Box 7430 written in Python 3.

A a glance

Fritz!Box 7430 is a residential gateway device including a VDSL modem and a LAN-WAN router. Its web interface offers a variety of functionalities and exposes data relevant to the power user. While detailed information on the DSL status and health are available, there is no built-in mechanism to record them. The box appliance does not offer any API to access data in a programatic way.


  • Simulates login
  • Retrieves data from the DSL information page (using HTML scraping)
  • Stores them in CSV files

Collected data include current and attainable throughput, S/N ratio, CRC error count and approximate cable length.

This is a "scratch your own itch project". I wanted to able to detect internet connectivity issues early on in order to report them to my ISP without delay. It is therefore a mixed bag of data scraping, data collection and, hopefully at a later stage, of data aggragation, reporting and alerting.


  1. Clone this repository
  2. Run and/or with Python 3
  3. Analyse the collected data

One time info will give you an insight on your DSL connection.

$  python3 -H -p mypassword
max_dslam_throughput_down: 70000
max_dslam_throughput_up: 20000
attainable_throughput_down: 128843
attainable_throughput_up: 27568
current_throughput_down: 69997
current_throughput_up: 19999
seamless_rate_adaptation_down: off
seamless_rate_adaptation_up: off
latency_down: fast
latency_up: fast
impulse_noise_protection_down: 41
impulse_noise_protection_up: 42
g_inp_down: on
g_inp_up: on
signal_to_noise_ratio_down: 23
signal_to_noise_ratio_up: 10
bitswap_down: on
bitswap_up: on
line_attenuation_down: 7
line_attenuation_up: 5
approximate_line_length: 163
profile: 17a
g_vector_down: full
g_vector_up: full
carrier_record_down: A43
carrier_record_up: A43
fritzbox_seconds_with_errors: 0
fritzbox_seconds_with_many_errors: 0
fritzbox_crc_errors_per_minute: 0
fritzbox_crc_errors_last_15_m: 0
central_exchange_seconds_with_errors: 1
central_exchange_seconds_with_many_errors: 0
central_exchange_crc_errors_per_minute: 0.02
central_exchange_crc_errors_last_15_m: 0

Store connection data stores the DSL info in a CSV file. It is intended to be executed on a regular basis, typically several times per day with a crontab:

$  python3 -H -p mypassword -d data

The destination directory data must exist. One file will be created per day, for instance:

$ head -3 data/20190101.csv

Analyse, alert and report

It is all very good to hoard data, but how do you act on them? If the connection drops to a clearly unacceptable levelm for instance less than 1Mbps up, an alert would be in order. But should you send an alert as soon as the bandwith drops, even if the modem was acquiring a new IP? It's probably ok if it happens once a day but not ok if the connection fails several times. How do you tell the two apart? How do you interpret the CRC errors? Here, the download Bandwith is 70Mbps, although not long ago, it was 85Mps. How should this be highlighted in a report, should and alert be sent? Should I complain to my ISP?

This part is a TODO.

Technical information


fritz-dsl-mon first simulates a login on the web interface. This part is a bit tricky as the web page relies on Javascript to md5 encode a challenge. From there, a POST can be executed to receive a sid. The reason why the box works this way is unknown.

HTML scraping

Although some pages receive pure JSON from the applicance, the interessting bits on the DSL information page are only available in HMTL. The content is therefore scraped, old school, with all the associated risks and fragility. See some examples in the samples directory.

Known issues and limitations

  • Errors are logged in error.log but an empty entry should be added to the CSV file.


For sid with md5 encoded challenge: fritzswitch - Switch your Fritz!DECT200 via command line. Copyright (C) 2014 Richard "Shred" Körber and released under GNU GPL license


Licensed under the GNU GPL license. See Copyright (C) 2019 Youri Ackx unless stated otherwise.

You can’t perform that action at this time.
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.