Guide Web Basics

URL Anatomy: Slugs, Query Strings & Redirects

Understand the pieces of a web address and how slugs, query parameters, percent-encoding, and redirects fit together.

2 min readUpdated October 5, 2026

The URL Slug Generator, URL Encoder & Decoder, and Redirect Generator each work with a different part of this topic. A web address can look like one long string, but it is built from distinct parts that serve different jobs. Understanding those parts makes URL debugging, campaign tracking, redirects, and application development much easier.

Scheme

In https://example.com/, https is the scheme. It tells the client how to communicate with the resource.

Host

example.com is the host. It can include a subdomain such as www.example.com or app.example.com.

Path and slug

In /guides/url-anatomy/, the path identifies a resource within the site. The final human-readable segment is often called the slug.

Query string

A question mark begins the query portion, such as ?utm_source=newsletter&page=2. Ampersands commonly separate name/value pairs. Query parameters are useful for filters, pagination, tracking, and application state.

Fragment

A hash begins the fragment, such as #pricing. Browsers commonly use it to jump to an element within the current document. The fragment is normally not sent to the web server as part of the HTTP request.

Percent-encoding

When data contains characters that would otherwise have syntactic meaning in a URL, percent-encoding represents those bytes safely. Application code should use URL APIs instead of manually replacing a few characters.

Redirects

If a public URL changes, a redirect can send visitors from the old location to the new one. Permanent changes normally use a permanent redirect and should be paired with updated internal links.

Readable URLs still need useful content

A clean slug helps humans understand a URL, but it is not a substitute for a useful page. Treat URL design as information architecture, not as a trick for ranking.