Adam Chipperfield

The popularity of the Jamstack is making the web a better place. Websites are getting faster, developers are becoming happier and usability is improving. We're going back to the basics of the web by replacing heavy, server-side technologies with everything we first learnt: Javascript, APIs and Markup.

But why are we still seeing a surge of server-side rendered websites claiming to be on the Jamstack?

SEO is ruining the web

Don't judge a book (this paragraph) by it's cover (the above heading). SEO is not runing the web. But it isn't making it easy for the Jamstack, which happens to be improving the web.

Let's go back to the basics of a webpage and how browsers read them: A search engine's bots visit a page and makes a decision about it based on it's HTML content (amongst other things).

Whilst this seems harmless, when you're rendering your content through JavaScript things get a little awkward. Most bots will not render JavaScript so they won't be parsing the rendered content. It's worth noting that Google have stated that their Googlebot does execute the page's JavaScript and parses the rendered HTML, but this is not enough to totally abandon our trusty servers.

Sell your Jamstack to the crawlers

If you want to stay true to the Jamstack and avoid server-side rendering then you need to tick all other boxes to enrich your website and have good SERP rankings. This isn't a post on SEO, but these are the base standards you should be adopting when building a Jamstack website.

Invite the robots in

Adding a robots meta tag with index, follow as the content will ensure the robots are going to take note of your page. Most site generators will provide this out of the box but it's extremely important that you check this out.

Describe your content

Whilst the content doesn't exist until the JavaScript is rendered you can still tell the crawlers what the content is going to be about. Set unique, descriptive title tags and helpful, but rich, meta descriptions.

Use structured data

In short, structured data is a JSON object that you add to your HTML with further details about the page. It lets the search engines better understand what the page is about so they can make decisions on appearance and ranking. The properties you add are relative to the type of content, so use schema.org's documentation for reference.

Make it fast

This can be quite hard to achieve. We've all had a task land in our inbox to "make the site faster". It can be achieved by writing good code (Smaller, more efficient JavaScript for example) and tweaking your static server to deliver the website in less time. This is, of course, amongst a boatload of other improvements that can be made.

I'll work on a future post on all performance enhancing factors and why you should adopt a new mindset when building your pages.

A case for server-side rendering

There's a reason server-side rendering is gaining popularity amongst the Jamstack community. It's the safest way to serve the user a true initial view of your pages whilst still allowing further JavaScript rendering to take over and work its magic, and search engines like it too.

In combination with all of the practices mentioned above you're now showing the search engines the all-inclusive content without the need for JavaScript rendering.