Skip to main content

Your privacy

We store what the site needs to work, like a notice you closed or your domain shortlist. With your OK we also use Google Analytics to see which pages help people, and the Meta Pixel to measure which of our adverts work. Privacy policy

Serverlys

Getting startedServerlys team4 min read

How to build a bilingual website in English and Spanish

Summarize with:

Share:

How to build an English and Spanish website: URL structure, hreflang, translation, language switchers, and the SEO mistakes that hide one language from Google.

If your customers speak English and Spanish, your website should too. A properly built bilingual site does more than translate the words: each language gets its own pages that Google can index separately, so a customer who searches in Spanish finds your Spanish page, and the one who searches in English finds the English one.

This guide covers the decisions that matter, in the order you will face them, and the mistakes that most often make one language invisible in search.

1. Choose a URL structure

Each language needs its own address. Google recommends against showing different languages at the same URL depending on the visitor's browser or cookies, because its crawler would only ever see one version. There are three common structures:

StructureExampleNotes
Subdirectoryyourbusiness.com/es/Simplest to run and the usual choice for a local business. Both languages share one domain's authority.
Subdomaines.yourbusiness.comWorks, but is set up and tracked more like a separate site.
Separate domainyourbusiness.mxFor a business that genuinely serves another country, not just another language.

For a US business serving English and Spanish speakers in the same city, a /es/ subdirectory is almost always the right answer. Our guide to subdomains vs subdirectories covers the trade-offs in more depth.

2. Translate for people, not word by word

Machine translation is a reasonable first draft and a poor final one. It misses tone, mistranslates industry terms and produces phrases no native speaker would use, and customers notice immediately. Have a fluent speaker who knows your trade review every page, and decide early on a few questions:

  • Tú or usted? Usted is more formal and safer for professional services; tú feels warmer for retail and food. Pick one and use it everywhere.
  • Which Spanish? Write for the people you serve. A Miami audience, a Texas audience and a customer in Spain use different words for the same things.
  • Keep names consistent. Decide which service and product names stay in English and which are translated, then stick to it.
  • Translate everything on the page, including buttons, form labels, error messages, image alt text and the confirmation email.

3. Tell Google the pages are translations of each other

The hreflang annotation tells search engines that two pages are the same content in different languages, so they show the right one to each searcher instead of treating them as duplicates. Each page lists every version, including itself:

<link rel="alternate" hreflang="en" href="https://yourbusiness.com/services/" />
<link rel="alternate" hreflang="es" href="https://yourbusiness.com/es/servicios/" />
<link rel="alternate" hreflang="x-default" href="https://yourbusiness.com/services/" />

The rules that trip people up:

  • It must be reciprocal. If the English page points to the Spanish one, the Spanish page must point back. One-way annotations are ignored.
  • Use full URLs, including https://.
  • Each page is its own canonical. The Spanish page's canonical tag points to the Spanish page, never to the English one, or Google may drop it from results.
  • Add an x-default entry (x-default) for the version shown to everyone else, usually English.
  • Language codes are ISO codes: es for Spanish in general, or es-US if you specifically target Spanish speakers in the United States.

Most site platforms and multilingual plugins write these tags for you. After launch, view the page source of one English and one Spanish page and check that both sets are present and point at each other.

4. Set the page language

Each page should declare its language in the HTML, lang="es" on Spanish pages. Screen readers use it to switch pronunciation; without it, a Spanish page is read aloud with English pronunciation, which is close to unusable. It is also one of the checks in our website accessibility checklist.

5. Add a language switcher people can find

  • Put it in the header, on every page, in the same place.
  • Label each language in its own language: "English" and "Español", not "Spanish".
  • Avoid flags. A flag is a country, not a language, and Spanish is spoken in more than twenty countries.
  • Link to the same page in the other language, not back to the homepage.
  • Remember the visitor's choice for the rest of their visit.

6. Local search in both languages

People search differently in each language, so research keywords separately rather than translating your English ones. "Plomero cerca de mí" and "plumber near me" are different searches with different competition. On Google Business Profile, you can mention that you serve customers in Spanish, and reviews in either language help. More in the local SEO guide.

7. The parts people forget

  • Contact and booking forms, their error messages and the confirmation emails.
  • Your chat widget and any AI assistant: it should answer in the language the visitor writes in.
  • Phone answering: if Spanish-speaking customers call, someone or something should answer in Spanish. See AI receptionists for small business.
  • Legal pages, cookie banners and policies.
  • Page titles and meta descriptions for every Spanish page, written in Spanish.
  • The Spanish sitemap entries, so Google finds the new pages quickly.

8. Keep both languages in step

The most common way bilingual sites fail is not at launch but six months later, when prices change on the English page and nobody updates the Spanish one. Make updating both versions part of the same task, and if a page cannot be translated yet, leave it out of the Spanish menu rather than linking to an English page that pretends to be Spanish.

The author

Serverlys team

The people who run Serverlys hosting, domains and support. We write about what we see every day helping small businesses keep their websites fast, safe and online.

More from Serverlys team

A plan that still makes sense in year two

Free migration, free SSL and daily backups on every plan, with a 30-day money-back guarantee.

Prefer the phone? (305) 671-1272 · Existing customer? Client login