Generator for the official list of IANA TLDs.
List of TLDs from ICANN.
→ The list is here ←
Grab the tlds.json
file from this repo and use it however you want.
The file is re-generated weekly on Saturday at 9:41am UTC.
docker compose up
markdownlint
)View all available tasks:
make
Build your very own copy:
make build
Code authored by Ryan Parman. The Go code, Dockerfile
, and other “development-y” things are made available under the MIT License.
The TLD list itself (including the JSON-formatted tlds.json
file) are made available under the terms listed in IANA: Licensing Terms, which states either public domain or the Creative Commons CC0 1.0 Universal (CC0 1.0): Public Domain Dedication license.
This is a port of the generation bits of stephenmathieson/node-tlds
to Go. The original package suffers from the issues discussed in “npm & left-pad: Have We Forgotten How To Program?”, including depending on multiple third-party packages that are utterly unnecessary — even in JavaScript/Node.js.
I wanted to provide something more reliable, with no dependencies outside the standard library.