How can we decrease LOAD TIME of the website.

by 16 replies
19
Dear All

Kindly let me know that how can we decrease load time of the websites if it takes 5 to 6 seconds
#programming #decrease #load #time #website
  • try to lowered sizes of images
    • [1] reply
    • I don't think slicing would have any effect on how fast the webpage would load, in fact using that many images would decrease load times and harm your site.

      Uusing as few images as possible is generally the best idea for a fast loading responsive site, not creating a website entirely out of them.

      The days of creating a design on photoshop, slicing in where your buttons/text will fit and saving it for web is gone. Everyone should be using XHTML/CSS first, and THEN using images to fill in the gaps.
  • That TOTALLY depends on what your site is doing! If it is fetching a remote feed every time the page loads then it could take 15 seconds every time, and the answer would be to cache the feed, say. If you have 50 plugins installed on a Wordpress blog, well, there's your problem. So you have to be a bit more specific about what the site is doing. But some sort of caching is probably going to be involved, and it usually does wonders.
    • [1] reply
    • Get FireFox.
      Install the FireBug plugin.
      Install the PageSpeed extension.

      Using PageSpeed will give you insights as to why your pages are loading slow.

      You may also be on a bloated webserver, hosting too many sites.
      • [1] reply
  • It depends on your site.

    If your site is using a lot of images, you might want to decrease the sizes of the images. If you're using wordpress, you might want to Install a cache plugin or uninstall unnecessary plugins.

    It totally depends on what your site has, your host and the internet connection speed of the site visitor.
    • [1] reply
    • That isn't an easy question.

      First: Which loading time do you mean? The HTML code of the page or the page + images?

      If it is the code alone you should get a) a more powerful server or b) let your code get optimized.

      Database queries can be cached, remote content can be cached, queries and file access can be optimized.

      If your files are too large: You can compress .css and .js files (spaces etc. will be removed) Also you can save images with more compression (reduced quality)

      Some of the tips you already got in this thread are very useful, especially Firebug. It's got a nice graph to show you which content of the site load at which time?
  • Step by step:

    ✜ Download & install this Firefox extension: https://addons.mozilla.org/en-US/firefox/addon/1843/.

    ✜ Restart the browser and click on the icon of the little bug to open the Firebug frame.

    ✜ Click the net tab.

    ✜ Navigate to your site.



    Now you know what's slowing things down.
    Maybe it's a slow script?
    Maybe your images are weighty and you need to convert a few to GIF's.

    Depends on the page in question.
    • [ 1 ] Thanks
  • The best way is try to use less images in your site.And not add more than 60 link to one page.
  • I use Super Cache on my wordpress, check it out: WordPress Super Cache
  • Take Flash out if you got a large Flash file in it.

    Timo
  • I would check out firebug and the Yslow plugin. In the yslow plugin they tell you the steps that you should take to improve your site page load speed.

    There are several ways to increase the speed of your site, you can move out your images and larger files off to a faster serving site (like amazon storage service), and then you can just have content.
    You can install memcache on your server and have your data that is not updated every time someone visits your site moved to the cache, and have the cache update once a day or how ever often you update your blog.
    You could turn your images into sprites so that the web browser only downloads 1 image versus several (and your css does the work of placing the images in the correct spot)
    You can make sure that you're using tableless design - tables must be rendered completely first before the information is displayed.

    These are ideas off the top of my head, and some of them were probably mentioned before ... I'd be able to provide more ideas if we saw what site you were trying to improve.
  • If you are using static html website, try to decrease the image size
    If you are using web app website such as PHP, you need to cache your website, such as APC, or xcache.
  • As others have said, use a combination of the Firebug plugin and Yahoos' Yslow plugin to see exactly what's taking the longest to load on your site.

    A few best practice things you could consider:

    Location of server
    Host your website on a server in the country that you're targeting. E.g if you're targeting Americans, host in America, English-host in the UK and so on.

    Lossless compression for images
    Make sure you run your images through Lossless compression software like Yahoos' Smush.it () service. There's no loss in quality!

    CSS sprites
    Consider using CSS sprites. Basically you put your sites most commonly used images into a single file () and then use css to cut out the image you want. If you have 30 images on a page then that's 30 separate requests the browser has to make. With CSS sprites, it's just 1 request!

    gzip compression
    gzip compression basically zips the page up before sending it to the browser, where it is then unzipped. This can dramatically decrease page size and speed up the browsing experience.

    Ensure gzip compression is enabled on your server. If you're using Wordpress or a similar CMS, check if it's using gzip. Wordpress by default does NOT make use of gzip compression. You can add the following to your template header file to force it to use gzip:

    <? //Compress content
    ob_start("ob_gzhandler");
    ?>

    Consolidate JS and CSS files
    Where possible, try consolidate all your JS and CSS files. Again this means less requests required between the visitor and your server.

    Click to play flash
    If you use or include a lot of flash videos then consider using a plugin which requires a user to click on a play button before the Flash content is fetched.

    Take a Youtube video embed for example. Not much bandwidth is used until the user clicks play on the video. But it's still a flash object which uses bandwidth and processing power to render.

    Sites like , which include a lot of flash videos, are always careful to place the video after 'the break' (post preview). This is so that when people visit the homepage and see a preview of all the posts, they don't end up fetching 20 flash video holders.

Next Topics on Trending Feed