Find out whether you need a static or a dynamic website
It doesn’t mean that static websites are necessarily better. It really depends on the situation. You should ask yourself whether or not you need an entire CMS. In some cases a much simpler static site is sufficient. We have seen a lot of sites that really do not need a CMS and would be just fine as a static site.
To speed up a dynamic site, there are a lot of techniques that, for example, involve caching to improve the responsiveness of your site. Sites with a CMS are more complex and tend to have more potential security issues and less server-side maintenance. Static sites are also easier to host and easier to move to another hosting provider because of the lack of a database.
Use caching for page's assets
Set up browser caching
Bundle the site’s assets
Optimise your images
Use non-blocking loading for the site’s assets
<script src ="/js/index.js"></script>
<script src ="/js/index.js" async defer></script>
Optimise the loading of fonts
Fonts you use in your websites can be the default fonts from the browser or operating system, web fonts from a font distributor such as GoogleFonts, TypeKit, free fonts from FontSquirrel or self-hosted. If you use web fonts from a font distributor they provide you with all the information you need to load their fonts. Make sure to load the fonts asynchronously. During the rendering of your page, this can cause a small glitch when the fonts are loaded and replace the fallback fonts from the browser or OS.
Consider using a content delivery network (CDN)
Font distributors often make use of a content delivery network (CDN) to serve their fonts. This means that the fonts are hosted from multiple data centres to make them quickly available from geographically distributed locations. If you host your fonts you can consider moving these to a CDN to reduce the load on your web server.
<link rel="stylesheet" href="https://d33wubrfki0l68.cloudfront.net/css/17193dddd4ab37ca8fd9fc93ac75ab4645294abd/css/styles.css">
<script src ="https://d33wubrfki0l68.cloudfront.net/bundles/2b8a7b2b62285124998f8c6c51392cdd44279e75.js" async defer></script>
Test the rendering speed of your site
Well known tools to test the rendering speed of your site and to help you find solutions are:
If you have applied some of the methods and techniques here you can use these tools to verify if your site's performance increased and everything is set up correctly.
Not all hosting providers are that fast. If you experience long loading times on your site even though it is optimized, then you can consider moving your site to a hosting provider with a better track record. If you need a CMS, the page speed is also affected by the performance of the database and the database front end at your hosting provider.
Consider Accelerated Mobile Pages
Another way to create fast pages is to make use of Accelerated Mobile Pages (AMP). This is a framework optimised for mobile browsing. Basically you create a shallow copy of your webpage with limited functionality served from a caching server by Google. CMS’s provide modules to manage AMP pages, such as for Drupal and WordPress. Webpages do load faster on mobile devices however there is a lot of criticism on this framework. Many see this as a method of Google to dictate how websites are built and how the web works.
We hope we provided you with a good start to build blazingly fast sites. When you have built a fast website you want to be sure it is available for your public. You might be interested in our website and server monitoring tool.