SEO tips I apply to all my projects

Last updated

Antonio Ufano avatar

Antonio Ufano

I'm writing this article to list all the things related to SEO that I consider a minimum to keep your website highly ranked by search engines (Google, Bing, DuckDuckGo etc)

Disclaimer: I don't consider myself an expert in SEO so I'm pretty sure I'd miss some things. Feel free to contact me with any other tips or comments and I'll add them to the list 😉

SEO development tips

  1. Add a robots.txt file to your site. You can see more info about it in this article by Google.
  2. Create a sitemap.xml of your site. The sitemap file contains all pages of your site and a priority so Search engines know which pages or your site are more important. You can use online tools like sitemaps.com. For dynamic pages (like blogs) try to keep it updated or use a package to re-generate it
  3. Try to generate descriptive URLs, for example using slugs in blogs.
  4. Dynamically change the title and page description for each page of your site.
  5. Add open graph and social media meta tags. You can even use services like Imageee to generate dynamic images for your sites.
  6. When using external libraries, always check multiple alternatives and use the ones with the smallest bundle size. For JS, you can check the details of a library and alternatives in bundlephobia

SEO performance tips

  1. Minify your JS
  2. Optimize your CSS using PurgeCSS. This is pretty useful when working with libraries like Bootstrap or TailwindCSS as most of the times we end up using a very small percentage of the whole library. PurgeCSS can remove all unused classes from your bundle, making your final CSS way smaller.
  3. Optimize your images using Squoosh. On average, I'm saving around 80% of size by passing my images through it and the quality loss is minimum.

Other tools and audits

  1. Use CloudFlare DNS so your site is cached and served from their CDN. I've seen a huge performance improvement by just doing this. You'll just need to open a free account in CloudFlare, add your site to the free plan and change your DNS in your domain registrar (Namecheap, Godaddy, Ionos, Porkbun...) to the ones provided by CloudFlare.
  2. Run LightHouse audit using Chrome and keep scores as high as you can. I know this sounds pretty generic but the generated report gives you tips on how to fix the most common issues. Just remember to run the audit and fix as many things as you can.
  3. Add your site to Google Search Console and add your sitemap so Google knows which pages to index and how to prioritize them. Also, check this Youtube playlist by Google
  4. Use an Analytics tool, like Google Analytics or, if you prefer something with better privacy, check Simple Analytics.

Hope you find this useful. If so, consider sharing it with your peers 😄

I'll try to keep this article updated as much as possible with more tips.

Happy coding!

If you enjoyed this article consider sharing it on social media or buying me a coffee ✌️

Oh! and don't forget to follow me on Twitter where I share tons of dev tips 🤙

Other articles that might help you

my projects

Apart from writing articles in this blog, I spent most of my time working on my personal projects.

lifeboard.app logo

theLIFEBOARD.app

theLIFEBOARD is a weekly planner that helps people achieve their goals, create new habits and avoid burnout. It encourages you to plan and review each week so you can easily identify ways to improve your productivity while keeping track of your progress.

Request early access
soliditytips.com logo

SolidityTips.com

I'm very interested in blockchain, smart contracts and all the possiblilities chains like Ethereum can bring to the web. SolidityTips is a blog in which I share everything I learn about Solidity and Web3 development.

Check it out if you want to learn Solidity
quicktalks.io logo

Quicktalks.io

Quicktalks is a place where indie hackers, makers, creators and entrepreneurs share their knowledge, ideas, lessons learned, failures and tactics they use to build successfull online products and businesses. It'll contain recorded short interviews with indie makers.

Message me to be part of it