You can decrease load times on your website by compressing the contents.
You can do this on any website (home-made, WordPress, Joomla, etc.) with gzip using the Apache module mod_deflate.
To do this, you first need to create a file in your public_html directory called ".htaccess" or edit your existing .htaccess file.
The .htaccess file is a configuration file in which you can configure many things, of which compression is just one.
In this .htaccess file, you can specify types of file to be compressed with directives like this (just keep the lines for the file types you want to compress):
#Deflate
#Make Sure Resources Are Compressed In Transit
<IfModule mod_deflate.c>
AddOutputFilterByType DEFLATE text/html
AddOutputFilterByType DEFLATE text/css
AddOutputFilterByType DEFLATE text/javascript
AddOutputFilterByType DEFLATE text/xml
AddOutputFilterByType DEFLATE text/plain
AddOutputFilterByType DEFLATE image/x-icon
AddOutputFilterByType DEFLATE image/svg+xml
AddOutputFilterByType DEFLATE application/rss+xml
AddOutputFilterByType DEFLATE application/javascript
AddOutputFilterByType DEFLATE application/x-javascript
AddOutputFilterByType DEFLATE application/xml
AddOutputFilterByType DEFLATE application/xhtml+xml
AddOutputFilterByType DEFLATE application/x-font
AddOutputFilterByType DEFLATE application/x-font-truetype
AddOutputFilterByType DEFLATE application/x-font-ttf
AddOutputFilterByType DEFLATE application/x-font-otf
AddOutputFilterByType DEFLATE application/x-font-opentype
AddOutputFilterByType DEFLATE application/vnd.ms-fontobject
AddOutputFilterByType DEFLATE font/ttf
AddOutputFilterByType DEFLATE font/otf
AddOutputFilterByType DEFLATE font/opentype
# For Olders Browsers Which Can Not Handle Compression
BrowserMatch ^Mozilla/4 gzip-only-text/html
BrowserMatch ^Mozilla/4\.0[678] no-gzip
BrowserMatch \bMSIE !no-gzip !gzip-only-text/html
</IfModule>
The full documentation on using this mod_deflate can be found here:
http://httpd.apache.org/docs/2.4/mod/mod_deflate.html
Alternatively, in a PHP based website you can implement gzip compression directly in the code.
This is done using ob_gzhandler which is done as part of the ob_start function. The full documentation on this can be found here: