URL Parser and Query String Editor

A URL splits into a protocol (https:), an optional username and password, a host name, an optional port, a path, a query string after ? and a fragment after #. Paste any link below to see each part, decode the query parameters into an editable table and rebuild the link with your changes.

Parts of https://shop.example.com:8080/shoes/run?size=9&color=red#reviews
PartValue
protocolhttps:
hostnameshop.example.com
port8080
pathname/shoes/run
search?size=9&color=red
hash#reviews

Updated

Three small tools in one place: a URL parser with a query parameter editor and UTM fields, a user agent reader, and a searchable list of the MIME types web servers send most often.

MIME types list

Common MIME types for the web
ExtensionMIME typeUsed for
.htmltext/htmlWeb pages
.csstext/cssStylesheets
.js / .mjstext/javascriptScripts (the current standard type; application/javascript is obsolete)
.jsonapplication/jsonData and API responses
.webmanifestapplication/manifest+jsonWeb app manifest
.xmlapplication/xmlXML documents, sitemaps
.txttext/plainPlain text, robots.txt
.csvtext/csvSpreadsheet data
.mdtext/markdownMarkdown
.pdfapplication/pdfDocuments
.zipapplication/zipArchives
.pngimage/pngLossless images
.jpg / .jpegimage/jpegPhotos
.webpimage/webpModern images
.avifimage/avifModern images
.gifimage/gifAnimations
.svgimage/svg+xmlVector images
.icoimage/vnd.microsoft.iconFavicons (image/x-icon is also widely used)
.woff2font/woff2Web fonts
.wofffont/woffWeb fonts (older)
.ttffont/ttfDesktop fonts
.otffont/otfDesktop fonts
.mp4video/mp4Video
.webmvideo/webmVideo
.mp3audio/mpegAudio
.wavaudio/wavAudio
.icstext/calendarCalendar invites
.wasmapplication/wasmWebAssembly

Why parse URLs with the platform parser

Splitting a URL with a regular expression or string methods breaks on the edge cases: user info before the host, IPv6 addresses in square brackets, ports, encoded characters and relative paths. The URL class built into browsers and Node follows the WHATWG URL Standard, so it handles all of those the same way the browser does when someone clicks the link.

It also normalises as it goes. The host is lowercased, default ports are dropped and dot segments in the path are resolved, which is handy when comparing two links that look different but point to the same place.

Keeping UTM tags tidy

UTM parameters tell analytics which campaign sent a visitor. Pick one spelling per source and medium and stick to it, because email, Email and e-mail show up as three separate rows in reports.

Never add UTM tags to internal links on your own site. They start a new session in most analytics tools and overwrite the real source of the visit.

How it works

  1. Paste a URL. If you leave out https://, the parser adds it so a bare domain still works.
  2. Read each part in the table, with the query string decoded into name and value rows.
  3. Edit, add or remove parameters, or fill in the UTM fields, then copy the rebuilt URL.
  4. Switch to the User agent tab to read a browser string, or the MIME types tab to look up a file extension.

Tips

Frequently asked questions

What is the difference between host and hostname?

hostname is the domain or IP address alone, such as shop.example.com. host adds the port when one is given, such as shop.example.com:8080. When the port is the default for the protocol (443 for https), the parser leaves it out of both.

How do I get query parameters in JavaScript?

Use new URL(link).searchParams, then call get("name") for one value or getAll("name") for repeated keys. For the current page, new URLSearchParams(location.search) does the same job. Both decode percent-encoding for you.

How reliable is user agent parsing?

Treat it as a hint. Chromium-based browsers now report a reduced string where the operating system version and device model are frozen to fixed values, and any browser can send whatever string it likes. For feature decisions, test for the feature itself instead.

What MIME type should JavaScript files use?

text/javascript. The current specification (RFC 9239) makes it the one standard type and marks application/javascript and the others as obsolete, though browsers still accept them.

Does the tool send my URLs anywhere?

No. Parsing happens in your browser with its built-in URL parser and nothing is uploaded or logged.

Related: URL encoder and decoder, UTM builder, Redirect checker, HTML entities, HTML links guide.

Start for free or see all free tools. We.Inc is free to start, with no card needed. AI building is on paid plans from $20 a month.

More in Free Tools

We.Inc is an AI-powered website builder you can resell under your own brand. Launch a branded client dashboard, bill on Stripe Connect, and deliver AI-generated websites in minutes. White-label plans start at $99 a month for 25 client sites, with a 7-day free trial and no per-site fees.

Product

Who It's For

Features

Resources

Company

View Sitemap