To give you a little background, I have a website with WordPress as my content management system, which revolves around users uploading panoramic photos. The site is hosted on a small Amazon EC2 instance. After encountering a few days of noticeably slow speeds, I decided to address the issue. In following the suggestions of several speed diagnostic sites (i.e., enabling browser caching, gzip compression, and keep-alive), I was able to increase my scores substantially and speed over basic site usage. Unfortunately the site remains incredibly slow when uploading files as panoramic photos tend to be large in nature. When a user uploads a file, a new post is created with a resized version of the panoramic image, and once complete, the user is redirected to the new URL. Does anyone have any suggestions to expedite this process? Are there any options besides upgrading my server?
The following plugin does exactly that:
Dynamic Image Resizer
Changes the way WordPress creates images to make it generate the images only when they are actually used somewhere, on the fly. Images created thusly will be saved in the normal upload directories, for later fast sending by the webserver. The result is that space is saved (since images are only created when needed), and uploading images is much faster (since it's not generating the images on upload anymore).
The author is WordPress core developer and knows WP code inside out.
Related
What can WooCommerce site owners do to optimize their site. Those owners are those to whom I developed an online store.
After some time of operation, the site gets bigger in disk size, I suppose it's due to a growth in the mySql database.
Is there a plugin that the customers can use to optimize their site without knowing anything about databases and wordpress tech stuff?
There are a lot of guides on how to optimize WordPress websites. Here is one. The most basic thing everyone should do is to use a caching and image optimization plugin.
But for WooCommerce specific actions that you can take, the one thing you can do is install the custom orders table plugin. This puts all of the WooCommerce data in a separate database table. However, it does require using wp-cli, so a person would have to know how to SSH in and run the command. It is easy to automate doing this though.
As for bigger disk sizes, if a WordPress database is more than a few GB in size something is terribly wrong. Normally it's only a few hundred MBs. So no, large websites don't happen because the database growing. It's from the stuff getting stored in the wp-contents folder. WordPress stores will store multiple copies of each image at different resolutions, and this along with having lots of plugins and themes downloaded can increase the size of the website, but it still won't get ridiculously big. Although once you add a backup plugin on top of the size of the website gets multiplied. A good backup plugin should default to not keeping around too many local backups. The most serious issues I've seen happen when there are multiple backup plugins, and they start including in their backups all of the backups created by the other plugin. You will then get exponentially bigger backups, and the size of the website will quickly get out of control.
So that's what causes websites to be bigger, and website owners will inevitably add more plugins and images to the site over time, increasing the size of the website, but even worse, all of the additional plugins will slow the website down.
You also need to make sure you're clients are using a good webhost. The guide I shared has some criteria you can use to judge a good hosting company. The one thing that many hosting companies don't have is some sort of in memory cache. Look for hosting companies that use Varnish or Litespeed or Nginx's proxy_cache to cache pages before they hit WordPress.
I did all the things Like image optimization, rendering for page speed optimization. I checked my mobile page speed increasing but desktop page speed not increasing it's still 22 again and again. I want to know why I am facing this problem. My website is www.sagorkhan.com. Can anyone please help me?
enter image description here
There are many factors that could affect your page speed and actually I see you've done a good job so far but you may go a litter farther.
I've tested your site with google page speed, pingdom tool, gtmetrix, webpagetest and here is my conclusion:
I guess your problem is about how to reduce server response time. While testing your site, it took more than 3+ seconds (6 on webpagetest) to completely load which may be considered a huge time. Reduce the server response time is not an easy task and could be a real challenge but here is a few tips:
1. Images optimization:
You said that you've done image optimization but still, your site have some huge images, one of them for example, is about 1MB which is can really affect the server response time. These images can be easily optimized, just go to google page speed and after you test your site scroll down and find: Download optimized image, JavaScript, and CSS resources for this page. Download the zip file and try to replace the old images with optimized ones using any FTP client, FileZilla is more then good for that.
Note that you can find the images locations under Optimize images section in case you don't know the location. Repeat that step again to make sure all your images are optimized.
Also I'd recommend some plugins like wp-smushit for optimize and compress all of your images and Regenerate Thumbnails to fix Serve scaled images issue. tinypng is good online alternative too if you like to do it manually.
2. Optimize CSS Delivery
That's not easy actually because it may requires to optimize the code and structure of your theme but you can give Autoptimize or W3 Total cache a try. Both support combining and minifying all enqueued JS, and CSS files.
3. CDNs:
CDN can really accelerate your site and greatly reducing your page loading time. Now, there are tons of good CDNs providers but I would recommend CloudFlare as a start since its free and easy to use and their free plan is enough and does work really great.
4. Caching
WordPress caching is a must if you care about performance, I don't see any sign of caching plugins except your HTML, JavaScript, css files is minified already which is good but not enough. I would recommend W3 Total Cache or WP Super Cache.
5. Web Hosting
If you're hosing your site in a shared host, don't hope too much to get perfect page speed even if you done all the required optimization. I'd definitely recommend upgrading to a VPS since its kinda cheap (unmanaged servers can be cheaper then shared host) and not that hard to setup and secure, A small VPS server can have a significant impact on page load speed.
You are resizing massive images using HTML/CSS when you should be resizing them individually using Photoshop or a similar image editing tool. You have a lot of render blocking js, specifically they're the YouTube scripts you're running.
Another big issue is the sheer amount of stylesheet and js files you're loading -- 19 js and 13 css. Try combining your js files together as much as you can, as well as your css files ... you're going to want to minify them as well.
You're loading many components from various sources, adding more http request overhead. If it's possible, you should consider hosting your own copies of some files.
Take a look at the output from https://gtmetrix.com/reports/sagorkhan.com/cBTMzOjD ... that should get you on the road to optimizing. Make sure you take your time reading the pagespeed and yslow tabs.
I have a wordpress site, and it has more that 30k posts.
Every post has own feature image, and each feature image has 10 responsive sizes.
#10076 post has 13 thumbnails
So there are about 300k image files, and this reaches to the File Usage Limit(inode limit) of hosting service.
File Usage Indicator
How can I reduce the number of thumbnails?
For example, when we use 2~3 thumbnails, we can store 120k~180k posts.
Well, are there any other hosting services which can store more than 300k files?
Sure, it is possible. There are several plugins in the WP repository that will automatically push uploads to S3 or some other CDN (e.g. WP Offload S3 Lite).
But the biggest challenge you'll face is in migrating the huge collection of images you already have. Anything you run from a web browser will almost certainly die trying. WP-CLI is the only real option for large-scale maintenance tasks. Take a look at S3-Uploads.
Alternatively you could push files to S3 manually and dynamically rewrite media URLs in WordPress by hooking into post_thumbnail_html or some such. You could build a cachable "does this exist?" check into your filter so it only rewrites image URLs that can actually be found at Amazon.
empty your trash folder in File Manager and file usage will drop significantly.
I'm working on a online file library for one of my clients. It's a library for mostly PDFs and office documents. Because they are a huge amount(almost 2gb in files), I'm hosting them on another site(divshare), so that the hosting account we have doesn't get blocked by the excess of files, and also because of excess traffic downloading can generate.
So, my question is if there is a good download manager(even with some search for download categories and so) that can handle instead of local uploaded files, URLs of files hosted somewhere else?
The advice about any plugin or the like is very appreciated.
You ask how to code such manager, right? Otherwise, your are on the wrong site...
I think you need to make a kind of file manager, except that instead of generating HTML pages to view the files and act on them, it exposes a Web API, returning XML or Json data, that a WordPress plugin can manage.
From Divshare:
The DivShare Uploader Plugin for Wordpress replaces your regular
uploading frame with a DivShare upload form, allowing you to easily
upload and add files without ever leaving your "Write a Post" page.
It's a great way to speed up your blogging and take the load off your
servers when hosting big files and images.
It can be found here: http://www.divshare.com/integrate
Good Luck!
Marcelous
I have a website that has the functionality of dynamically loading the images. My website is getting slowed down if there are too many images (jpeg files).
How can I deal with such images ?
The website is built in Drupal.
-VJ
There are a few solutions for this type of issue, some of my recommendations are below.
Implement a CDN (Content Delivery Network) for your images, so they are delivered via a high bandwidth server, rather than yours.
Drupal has some useful tools to speed up sites, JS and CSS aggregation might do the trick.
I would recommend using a module called "Imagecache", this will allow you to control the size and quality of images that your users / yourself upload and display on the site.