TP-Link CLI

31 Subcommands • v1.0.0

Terminal Control for TP-Link Routers

Inspect RSRP/RSRQ/SINR radio metrics, lock carrier bands, read 2FA SMS tokens, auto-reboot, clamp MTU to 1420 GTP standards, and engage kernel BBR congestion control. Zero web UI lag.

$ curl -fsSL https://tp-link-cli.dulith.me/install.sh | bash

Verified across Linux, macOS, WSL2, Raspberry Pi & OpenWrt

apt: tplink-cli.deb npm: @dulith/tplink-cli pip: tplink-cli brew: tplink-cli docker: ghcr.io

Interactive Terminal Experience

Select a command to test live output simulations

dulith@sliit-malabe: ~ (tplink-cli v1.0.0)

Engineered to Crush Bufferbloat & Keep NAT Alive

Developed under real-world cellular broadband conditions in Malabe, Sri Lanka on the Hutch 4G 20Mbps Unlimited plan. Here is how three targeted optimizations deliver up to 340% lower loaded latency.

BBR Congestion Control

Replaces legacy Reno/Cubic loss-based algorithms with model-based bottleneck bandwidth and round-trip propagation time calculations. Eliminates queue buildup in cellular eNodeB buffers.

1420 MTU GTP Clamping

LTE Carrier EPC backhauls wrap packets in GPRS Tunneling Protocol (GTP-U) headers. Standard 1500 MTU packets fragment at the tower. Clamping to 1420 prevents fragmentation entirely.

ip link set dev wlan0 mtu 1420
iptables -t mangle -A POSTROUTING -p tcp -j TCPMSS --clamp-mss-to-pmtu

Carrier NAT Keepalive Pulse

Mobile providers tear down idle UDP connection states after 30-60 seconds, forcing radio reconnection stalls. Our 28-byte pulse fires every 25s, keeping the radio active for zero lag.

tplink-cli pulse --interval 25s
Payload: 28B ICMP/UDP echo (~3.2KB/hr)
Real Throughput
99% of 20Mbps cap
28 ms
Loaded Latency
Down from 184ms
0.0%
Fragmentation
MSS 1380 + MTU 1420
100%
Reversible
One-click revert

31 Universal Subcommands

Full feature parity with TP-Link 192.168.1.1 Web Admin GUI

tplink-cli status Diagnostics

Show full router & cellular telemetry

tplink-cli signal Cellular

Show RF signal metrics (RSRP, RSRQ, SNR)

tplink-cli cell-lock Cellular

View or configure LTE Cell Lock

--enable--disable--earfcn+1
tplink-cli dns System

Manage router DNS settings

tplink-cli ipv6 System

Toggle IPv6 stack (on/off)

tplink-cli ussd Cellular

Execute USSD query (e.g. *344# or *123#)

tplink-cli sms SMS

Read or send SMS

--limit--folder
tplink-cli reboot System

Reboot the router

-y--yes
tplink-cli profile Diagnostics

Check active network profile and gateway safety

tplink-cli config System

Manage stored credentials

tplink-cli cookie System

View or save browser session cookie

tplink-cli wifi-guard Wi-Fi

Verify and optimize Wi-Fi link stability (no Ethernet needed)

--optimize--fix
tplink-cli clients Diagnostics

List connected LAN devices (IP, MAC, Hostname)

tplink-cli reservation System

Manage DHCP static IP reservations

tplink-cli data-limit Cellular

View or set monthly cellular data cap

--limit--day
tplink-cli wifi Wi-Fi

View or configure Wi-Fi radios (2.4GHz / 5GHz)

--band--toggle--ssid
tplink-cli leds System

Control router LEDs and Night Mode schedule

--night-mode--start--end
tplink-cli diag Diagnostics

Run router WAN and internet diagnostic test

tplink-cli band Cellular

View or lock LTE Band (e.g. 3, 8, 40, auto)

tplink-cli calibrate Cellular

Autonomous RF band calibration & Live Web UI

--web--no-web--port+3
tplink-cli logs Diagnostics

Read or clear system & cellular event logs

--lines-n--module+4
tplink-cli guest-wifi Wi-Fi

View or configure dual-band Guest Wi-Fi

--toggle--band--ssid+4
tplink-cli port-forward System

Manage NAT virtual server port forwarding rules

tplink-cli dmz System

View or configure DMZ host forwarding

tplink-cli upnp System

Manage Universal Plug and Play (UPnP)

tplink-cli reboot-schedule System

Manage automated periodic reboot schedule

--time--mode+1
tplink-cli time System

View router system clock or trigger NTP sync

--sync
tplink-cli op-mode System

View router operation mode (3G/4G vs Wireless)

tplink-cli ddns System

View Dynamic DNS (DDNS) providers and status

tplink-cli fw-check System

Check for official TP-Link online firmware updates

tplink-cli repl System

Launch interactive REPL console

Zero-Friction Installation

Available across all major package ecosystems

curl -fsSL https://tp-link-cli.dulith.me/install.sh | bash
Verified clean on Python 3.10+, Node 18+, Go 1.22+
Config: TPLINK_ROUTER_IP TPLINK_PASSWORD