---
title: "Discussion on \"URL extraction for hostname, domain, subdomain and tld in Swift\" | Hashnode"
description: "Discussion on \"URL extraction for hostname, domain, subdomain and tld in Swift\". Learn about TLDExtract, a Swift package to extract top-level domain (TLD) second level domain, subdomain and root domain from a String or URL"
url: "https://hashnode.com/posts/url-extraction-for-hostname-domain-subdomain-and-tld-in-swift/64bdfe6b890566741b5ff0aa"
---

[Feed](https://hashnode.com/feed) /

Discussion

# [URL extraction for hostname, domain, subdomain and tld in Swift](https://blog.eidinger.info/url-extraction-for-hostname-domain-subdomain-and-tld-in-swift?utm_source=hashnode&utm_medium=feed)

Learn about TLDExtract, a Swift package to extract top-level domain (TLD) second level domain, subdomain and root domain from a String or URL

Jul 24, 2023 · 2 min read · blog.eidinger.info  
Read the article

-   [#swift](https://hashnode.com/tag/swift)

## Written by

[Marco Eidinger](https://hashnode.com/@MarcoEidinger)

@MarcoEidinger

  
[View profile](https://hashnode.com/@MarcoEidinger)

#Swift #iOS SDK architect 🇺🇸 🇩🇪

I am a Software Engineer working on open source and enterprise mobile SDKs for iOS and MacOS developers written in Swift. From 🇩🇪 and happily living in 🇺🇸

## Responses

Markdown supported · ⌘↵ to post

No responses yet.
