Five unusual ways to speed up your website

Performance 19 responses so far

We have already seen many great tips for speeding up a website. These tips are great, but I want to share with you five more tips that are less common. Generally these tricks can’t be used in every situation (just like any other trick), but they are useful to speed up your website even more and offer better experience to your visitors.

1. Use ASCII encoding over UTF-8

Using ASCII charset over UTF-8 will positively affect speed of the web page. Web page will speed up because ASCII is the smallest charset that we can use. Because browsers display HTML and XML only, every character will be translated to it’s HTML code. Translation process will be fastest if you use smallest charset (ASCII).

To use ASCII encoding, add this code to head section of page:

<meta charset=”us-ascii” />

Why I shouldn’t use ASCII encoding

If you have to use non ASCII characters (e.g. copyright sign) or you have to use language specific characters, you have to go with UTF-8 or some other charset that has characters you need.

2. Use internal CSS over External

Every time webpage is accessed, HTTP requests are made to get content of every external files needed for presentation of this page. Using internal CSS over external will help you speed up your web page by eliminating one or more requests for external CSS files.


Why I shouldn’t use internal CSS

If you decide to use internal CSS, you have to repeat same code on every page instead of just linking to one .css file. It will make harder for you to maintain your website, and if your website has many pages you will have to use much more space on hard drives because every page will get bigger due to CSS style being embeded into it.

3. Put whole JavaScript code into single file

If your web page uses Javascript, you should put whole Javascript code into single external Javascript file. Using single file instead of multiple files will help your website speed by eliminating unnecesary HTTP requests required for getting content of these files. If you use only one external file instead of two, HTTP request will be sent once instead of twice.



Web page speed could be further improved by embeding whole Javascript code on the end of the document, but this would hurt your SEO because search engine bots have problems with reading and interpreting Javascript.

Why I shouldn’t put whole Javascript code into single file

If you put whole Javascript code into single external file, it will be harder for you to to maintain or make changes to this code as neccesary.

4. Use file extension in URL

If you want to use extensionless url-s they will require you to set up .htaccess file (or any other equivalent) so that file extension will be added to url before accessing page. Url rewriting will unnecesarily take some time, which will result in slower web pages.


Many people thinks that extensionless url-s has additional SEO value over url-s with extension. This is not true. According to Matt Cutts, search engine bots like url-s with extension.

Why I shouldn’t use extensions in url

Url-s without extension looks cleaner and are also easier to remember by visitors. Using extensionless url-s will allow you to seamlesly switch from one technology to another in future (e.g html to php, php to asp). In that case you will only need to change extension to be added in .htaccess, instead of redirecting every old page to new one.

5. Avoid .htaccess usage

Any time you have to use .htaccess to rewrite url, you are slowing down your website. Although, url rewriting is very fast, it still takes some time especially if you have multiple rewrite rules in .htaccess file. Allowing access to a page directly would speed up your website a bit.


Why I should use .htaccess

If you can’t make SEO friendly url without rewriting url-s, then you should use .htaccess for rewriting. SEO benefit from SEO friendly url-s is much greater that disadvantage of having a bit slower website. Url rewriting is reccomended if you use url parameters.

The following two tabs change content below.
My name is Bojan Jovanovic . I am web developer and owner of website I also write about SEO and web development on my blog. If you want, feel free to get in touch with me on twitter

Latest posts by Bojan (see all)

  • Predrag Krstic

    1. and 2. are complete nonsense!

    1st US ASCII and US UTF8 will be the same size in most cases, there is no valid reason to go back to ascii anymore.

    2nd is ok only for small css and something like that doesn’t exists, this is not 1995 anymore, also think on mobile platforms where every byte counts. CSS is loaded in parallel with other code, and stored in browser cache.

  • Predrag Krstic

    what idiot put this filter on comments to make every first letter capital?

  • nomi

    I’d agree with Predrag. These techniques doesn’t make any sense.

  • Bojan

    Thanks for reading post and commenting!

    I don’t think that many websites use ASCII, but why would you use bigger charset if you don’t need any character that is not present in ASCII? You may see slight improvement in speed if you use smaller charset.

    2nd technique is perfectly valid to me. It will reduce response time of page, as one request is eliminated. Browsers handle internal CSS in the same way as external, except for caching.
    However, most of the users will come to website with empty cache.

    Before using this technique, you should refer to Google analytics account. If you have many new visitors, use this technique, or if you have many returning visitors and/or many pageviews per visit, you should think about using external CSS.

  • The HTAccess file is the best suggestion when self hosting in a manner that allows for writing directly to the config. However, inline CSS and ASCII over UTF-8 are not things I could possibly see people seriously implementing.

  • These tips really aren’t that valid at all. They are definitely “unusual” but how practical are they? Not very. In regards to #2 markup readability comes way before increasing a page load time by some unrecognizable margin.

    #4 seriously? Extensionless URLS are usually used when data is retrieved dynamically. Ever heard of MVC?

    This is more of a list of, “What not to do” than anything else.

  • When there are advantages for inlining ,css and even .js, and you want to keep site wide editbalility, I have used as many as needed at top and done similar with tags at the bottom of the document when script is okay to defer.

  • Ugh!

    My tags got eaten! try again…

    When there are advantages for inlining ,css and even .js, and you want to keep site wide editbalility, I have used <style …><?php $myCss = file_get_contetns(“some.css”); echo $myCss; ?> as many as needed </style> at top and done similar with <script> tags at the bottom of the document when script is okay to defer. Quite fast.

  • awesome tips for css. i am agree with you…… Thanks

  • About Rajasthan

    This blog really helped me. I am the owner of and this really helped my site to load faster . about rajasthan is about the places and events in rajasthan. .
    Thanks to

  • Bojan

    Thanks to everyone who commented! I appreciate your time to give feedback.

  • Ha.. Realy Nice Technic For All Commenters For Commenting First Letter In Capital ,,.. That Was Nice Thinking Admin…

    This Blog Informaion Should Help Everyone For Their Desinging And Development Work.. Thanks For Sharing…..

  • Its really good to know about the factors to increase the page speed of any website.
    Having long term hosting services help the website to increase the page speed?


  • Jay

    Such a nice website… such a fail with first letter capital !

  • Awesome post for speeding the website, Using file extension in URL and avoiding .htaccess usage are informative. To know more

  • It’s a great help for me. I want a fasten my loading times of my website. I’m sure this post will help me a lot. Thanks!

  • Nice Technique.. I will implement it to my website

  • It’s really a great discussion is going on. and i think all the techniques are good.
    website development company in jaipur

  • Basically as designer i use external and inline css and which supports me create quality website design.