Trim URL to Root
Keep only the scheme and host of each URL, dropping paths and query strings.
Input URLs
Paste one URL per line. Invalid entries are skipped.
Roots
One root URL per line.
Trim URL to Root
Paste full URLs and the trimmer keeps only the scheme and host — the origin — so https://example.com/blog/post?x=1 becomes https://example.com. Useful for grouping a mixed list by site.
Step by step
- Paste one URL per line. Invalid entries are skipped.
- Click Trim to Root.
- Check the counters for input URLs and output roots.
- Copy the roots and deduplicate them for a clean list of origins.
Tips for better results
- Use roots to count how many URLs a crawl covers per host, which quickly shows how spread out a scraping run is.
- The www prefix is preserved here, so normalise www and non-www afterwards if you need them merged.
- For hostname-only output that strips www, use Trim URL to Domain instead.
Frequently asked questions
What is a URL origin?
The scheme plus the host, for example https://www.example.com. Everything after the host — path, query and fragment — is dropped.
Does this keep the www prefix?
Yes. The host you paste is preserved exactly, including www, subdomains and port numbers.
How is this different from Trim URL to Domain?
This tool keeps the scheme and any www prefix. Trim URL to Domain returns only the hostname and removes www for consistency.
Related free SEO tools
Browse the full collection of free browser-based helpers or contact us with a general question.
Browse all tools