Opens in a new tab

Local SEO

URL slug: how to write SEO-friendly URLs

What a URL slug is, what Google recommends for URLs, seven steps to write a good one and what we found in our own 284 URLs.

CheckedNovember 3, 2026
Reading time
Listen to this guide
0:00 /5:27

Short answer: A URL slug is the part of an address that identifies a page, usually at the end, such as 301-redirect in /guides/301-redirect/. Google recommends simple, descriptive words in your audience’s language, hyphens between words and as few parameters as you can. Keep every URL in one case, because Google treats /APPLE and /apple as different addresses.

What Google recommends for URLs

Practice Do Avoid
Words Readable, descriptive words Long ID numbers
Language Your audience’s language, transliterated if needed Words your audience doesn’t search with
Separators Hyphens between words Underscores, or words joined together
Parameters As few as you can Parameters that don’t change the content, such as session IDs
Letter case One case for every address Two cases that open the same page
Fragments The History API if JavaScript changes the content A # fragment to change the content

From Google Search Central, “URL structure best practices for Google Search”, read November 3, 2026.

The slug of an address

MDN, the reference many web developers use, applies the idea to its own pages: the slug is the part of the address after the language and /docs/. In /guides/301-redirect/ the slug is 301-redirect, and the folder before it says the page is a guide.

On a site in two languages, each version gets its own slug in its own language. Our Spanish guide on the same topic lives at /es/guias/redireccion-301/. Our guide to hreflang covers how to tell Google the two pages go together.

Why the structure matters to Google

Google asks for URLs built logically and in the way that’s easiest for people to understand. If your URLs don’t meet its requirements, Google says it will likely crawl your site inefficiently.

Overly complex URLs, especially with several parameters, can create many addresses for the same or similar content. Googlebot may then use much more bandwidth than it needs, or fail to index all your content.

How to write a good URL

  1. Write the slug with a few readable words that say what the page is about.
  2. Use the language of the page, with translated words on each language version.
  3. Separate the words with hyphens, not underscores.
  4. Use one case for every URL; lowercase is the simplest.
  5. Group pages in folders that follow your site, such as /guides/ for guides.
  6. Leave out parameters that don’t change the content, such as session IDs.
  7. If you change a slug, redirect the old address to the new one with a 301 or 308.

Our guide to the 301 redirect explains how to set up that last step.

What our own URLs look like

At 2:52 AM on November 3 we checked the 284 URLs in our sitemap, 142 in English and 142 in Spanish. None has capital letters, underscores, parameters, # fragments or accented letters, and all end in a slash.

Our Spanish pages live under /es/ with Spanish words, written without accents or ñ, such as /es/diseno-web/, so no address needs percent-encoding. Most pages sit two or three folders deep, such as /seo/local-seo/.

We also found that our server answered capitalized versions, such as /GUIDES/301-REDIRECT/, with the same page and a 200, and /Es/ ones with a 404. Since 2:55 AM on November 3 they redirect with a 301 to the lowercase address.

Before you publish a URL

  • The slug says what the page is about.
  • The words are in the page’s language.
  • Hyphens separate the words.
  • The URL uses a single case.
  • No parameter is there that doesn’t change the content.
  • An old slug redirects to the new one.

RememberWrite short slugs with descriptive words in your visitors’ language, separated by hyphens and in one case. Change them as little as you can, and redirect the old address with a 301 or 308 when you do.

If you want us to check the URLs of your site, see our technical SEO service.

Quick answers about URL slugs

Should I use hyphens or underscores in URLs?

Hyphens. Google recommends them because they clearly mark where a word ends, while underscores are often used to keep words together, as in programming names such as format_date.

Do capital letters in a URL matter?

Yes. Google treats /APPLE and /apple as different URLs with their own content. If your server shows the same page for both, Google recommends converting all the text to one case.

Should Spanish URLs use accents or ñ?

You can use words in your audience’s language. Google asks you to percent-encode characters outside ASCII in your links, so writing them without accents, as we do with /es/diseno-web/, avoids the encoding.

How long should a URL slug be?

Google doesn’t set a length. It asks for a simple structure with readable words and as few parameters as you can, so keep the slug to the words that say what the page is about.

Should I change old URLs to make them better?

Only with a good reason. Google recommends a permanent 301 or 308 redirect from each old address, and warns that any big change can bring ranking swings while it crawls and indexes your site again.

Sources

Read on November 3, 2026. Google Search Central: URL structure best practices for Google Search and How to move a site. MDN: Slug. Our own case: the URLs in our sitemap and our server’s answers to capitalized addresses, on November 3, 2026.

Pedro Galindez

Pedro Galindez

Founder of Feedback Studios, a bilingual growth studio in Miami.

Listen0:00 /5:27

More guides

Checked November 3, 2026

Meta keywords: does Google still use them?

What Google does with the keywords meta tag, which meta tags it does read, seven steps to clean yours up and what our own pages send.

Checked November 3, 2026

JavaScript SEO: how Google renders your pages and what to check

How Google crawls, renders and indexes JavaScript pages, what scripts can change, seven checks and what our own pages send before JavaScript runs.

Checked November 3, 2026

Nofollow links: when to use nofollow, sponsored and ugc

What rel nofollow, sponsored and ugc tell Google, when to use each, seven steps to qualify your links and what our own pages use.

Checked November 3, 2026

Meta Ad Library: how to see any page’s Facebook and Instagram ads

What the Meta Ad Library shows for any active ad and for political ads, how to search it in seven steps and what it shows for our own page.

Checked November 3, 2026

Open Graph tags: what they are and how to control your link previews

What Open Graph tags do, the four every page needs, the image size and alt text, seven steps and what our own pages send.

Checked November 3, 2026

Google Ads conversion tracking: how to set it up in 2026

How Google Ads counts a conversion, how to set up website conversions step by step, calls, enhanced conversions, sales you close later and how to check it works.

Next step

Rather talk it through?

In a 20-minute call we look at your business and tell you what we would do first.