Site icon Impact Digital

Hyphens vs Underscores in URLs: What Google Now Says

A web address with hyphens between words shown next to one with underscores

If you run a WordPress blog, a small business site or a client portfolio, you have probably wondered whether the underscores in some of your URLs are hurting you. Google recently touched its URL documentation on exactly this point. This guide is for site owners and marketers who want to know what the page says, what it does not say, and whether any action is needed.

What changed in Google’s documentation

Google’s Search Central updates page lists an entry dated October 23, 2026, saying the URL structure best practices were updated “to clarify word separation guidelines using hyphens versus underscores.” The same page says the change was made to match episodes of a Google video series. Industry news sites have reported the change too, but everything below is based on Google’s own pages.

An earlier entry in the same changelog, from June 18, 2025, describes a reorganisation of the URL structure documentation “so it has a clearer flow.” That entry was a docs-only change. The October 2026 entry is also described as a clarification of guidance, not an announcement of new behaviour.

What the official page says about hyphens and underscores

On the current “URL structure best practices for Google Search” page, the relevant advice is to use hyphens to separate words. Google recommends hyphens instead of underscores, and gives a reason: “for historical reasons, we don’t recommend using underscores.” The page links this to programming languages, where an underscore is commonly used to join concepts, as in format_date. It also says that running words together with no separator, such as greendress, is not recommended.

Two details matter for how you read this:

The page has no “last updated” note, so it does not show which sentences changed; this article describes only what it says today.

What makes a good URL, according to the same page

The hyphen advice is one item in a longer list. The page splits its guidance into requirements for a crawlable structure and recommendations for readability. The table below summarises them.

TopicWhat the page says
Descriptive wordsPrefer readable words over long ID numbers, for example /wiki/Aviation rather than a parameter-heavy index.php URL.
Audience languageUse words in the language your audience searches in, with transliterations where they apply.
Non-ASCII charactersPercent-encode them in links. The page prefers gem%C3%BCse over gemüse.
Word separatorsUse hyphens, not underscores, and do not run words together.
ParametersUse as few as you can, and remove any that do not change the content. Use = and & in the standard way.
CaseURLs are case sensitive, so /APPLE and /apple are different URLs to Google. Pick one case and keep it consistent.
FragmentsGoogle generally does not support fragments such as /#/potatoes for changing content. Use the History API for JavaScript sites.
Multi-regional sitesA country domain or a country subdirectory such as /de/ makes geotargeting easier.

The same page also warns about structures that create many URLs for the same content, such as stacked filters, session IDs, endless calendars and broken relative links. For most small sites these are bigger risks than an underscore. If you suspect crawl problems, the guide on fixing crawl errors in Google Search Console is a sensible next step.

Should you change existing underscore URLs?

The documentation tells you what to prefer for URLs you create. It does not tell you to rewrite URLs that already exist, and it says nothing that makes underscore URLs a problem to fix urgently. So this part is a judgement call, and the trade-offs are practical rather than official.

Reasons to leave them alone

Reasons to change them

A reasonable default for most sites is simple: use hyphens for every new URL, leave established underscore URLs alone, and only convert them as part of a planned clean-up.

If you do change them, use 301 redirects

Google’s page on redirects says that if you need to change which URL appears in search results, permanent server-side redirects are recommended whenever possible. The 301 and 308 status codes both signal a permanent move. A permanent redirect tells Google the target should be treated as the canonical URL, and Google advises using one “when you’re sure that the redirect won’t be reverted.” The page lists server-side redirects, set in server configuration such as .htaccess on Apache or NGINX config, as the method most likely to be interpreted correctly. JavaScript redirects are described as a last resort.

The same page notes that the old URL may linger as an alternate name in results for a while after a move. It does not give a time limit for keeping redirects in place. Here is a cautious workflow, with the steps beyond Google’s redirect advice being general good practice rather than official requirements:

  1. Export a list of the underscore URLs and decide which are worth changing.
  2. Map each old URL to its new hyphenated URL on a one-to-one basis. Avoid sending many pages to the home page.
  3. Create permanent server-side redirects, using your host’s tools, a redirect plugin or server rules.
  4. Update internal links and your sitemap to the new URLs so you are not relying on the redirect. Our guide to smart internal linking covers how to do this tidily.
  5. Test a sample of old URLs, then watch the indexing and crawl reports in Search Console for errors.

WordPress permalink settings

In WordPress, go to Settings, then Permalinks. According to the WordPress documentation, the options are Plain, Day and name, Month and name, Numeric, Post name and Custom Structure. The Plain setting produces addresses like example.com/?p=N, which the documentation describes as not user-friendly and not optimised for search engines. WordPress installs with Plain as the default.

For most blogs, Post name is the simplest readable choice. The %postname% tag uses a sanitised version of the post title, which WordPress documents with the example “This Is A Great Post!” becoming this-is-a-great-post. In other words, WordPress separates words with hyphens by default. Underscores usually appear only when someone typed a custom slug, imported content from another system, or built the site on older software.

Be careful with two things:

The WordPress permalinks documentation does not promise an automatic redirect when a slug changes, so check what your theme, host or SEO plugin does before relying on one. For a broader look at URL habits, see best practices for URL optimisation.

Common mistakes to avoid

Key takeaways

FAQ

Does Google penalise underscores in URLs?

The official page does not say so. It recommends hyphens and does not recommend underscores, but it frames this as guidance for readable, understandable URLs. It does not describe a penalty.

Will switching to hyphens improve my rankings?

Nothing on the page promises that. Moving URLs also carries risk, so do not expect a ranking gain from the change alone.

What type of redirect should I use?

Google’s redirect page recommends permanent server-side redirects whenever possible when you need to change the URL shown in search results. Both 301 and 308 signal a permanent move.

Does WordPress use hyphens or underscores?

By default WordPress builds slugs from the post title with hyphens, as in the documented this-is-a-great-post example. Underscores generally come from manual edits or imported content.

Sources

Exit mobile version