#mod_deflate
Explore tagged Tumblr posts
Text
Optimización de Caché en Apache2
En este tutorial, se explorará cómo optimizar el rendimiento de un servidor Apache2 implementando técnicas avanzadas de caché. Se detallará el uso estratégico de los módulos mod_deflate, mod_headers y mod_expires para mejorar la entrega de contenido estático. A través de una configuración cuidadosa y la combinación de estos módulos, se demostrará cómo se puede aumentar la eficiencia y la…
View On WordPress
0 notes
Text
How to Optimize Your Computer Server for Maximum Performance?
Optimizing your computer server for maximum performance involves a series of steps that enhance its efficiency, reliability, and speed. Here are some detailed instructions to help you achieve this:
1. Hardware Optimization
a. Upgrade Server Hardware
RAM: Ensure your server has sufficient RAM. Upgrade to ECC (Error-Correcting Code) RAM for better reliability.
Storage: Use SSDs (Solid State Drives) instead of HDDs (Hard Disk Drives) for faster read/write speeds.
CPU: Upgrade to a more powerful CPU with higher clock speeds and more cores.
Network Interface Cards (NICs): High-speed NICs, such as 10GbE, are used to handle increased network traffic.
b. Maintain Hardware
Regular Cleaning: Dust and clean server components to prevent overheating.
Monitor Hardware Health: Use tools to monitor temperatures, voltages, and fan speeds.
2. Software Optimization
a. Optimize Operating System (OS)
Choose the Right OS: Select an OS tailored to your server's role (e.g., Linux distributions like Ubuntu Server or CentOS for web servers).
Update Regularly: Keep the OS and all software up to date with the latest patches and security updates.
Remove Unnecessary Services: Disable or uninstall services and applications that are not needed.
b. Optimize Applications
Database Optimization: Use indexing and query optimization techniques. Consider database clustering for load balancing.
Web Server Optimization: For Apache, use modules like mod_deflate for compression. For Nginx, adjust worker processes and caching settings.
Caching: Implement caching mechanisms such as Memcached or Redis to reduce database load.
3. Network Optimization
a. Configure Network Settings
Adjust TCP/IP Settings: Optimize parameters such as TCP window size and timeout settings.
DNS Configuration: Use reliable and fast DNS services.
b. Network Security
Firewall Configuration: Use firewalls to block unnecessary ports and protect against attacks.
Use VPNs: Secure remote access with VPNs to ensure encrypted connections.
4. Performance Monitoring and Tuning
a. Use Monitoring Tools
System Monitoring: Tools like Nagios, Zabbix, or Prometheus can provide insights into system performance and alert you to issues.
Log Analysis: Regularly analyze logs to detect and resolve errors and performance bottlenecks.
b. Regular Performance Tuning
Load Balancing: Distribute workloads across multiple servers to prevent any single server from being overwhelmed.
Scalability Planning: Plan for future growth by considering horizontal and vertical scaling options.
5. Security Enhancements
a. Regular Security Audits
Vulnerability Scanning: Use tools like Nessus to identify and address vulnerabilities.
Penetration Testing: Conduct regular penetration tests to find and fix security weaknesses.
b. Data Protection
Backups: Implement regular, automated backups and test restore procedures.
Encryption: Use encryption for sensitive data, both in transit and at rest.
6. Energy Efficiency
a. Power Management
Use Energy-Efficient Hardware: Choose energy-efficient hardware components.
Configure Power Settings: Adjust power settings to reduce consumption during low-usage periods.
b. Cooling Optimization
Efficient Cooling Systems: Use advanced cooling systems to maintain optimal temperatures.
Hot and Cold Aisle Containment: Implement hot and cold aisle containment in data centers to improve cooling efficiency.
Conclusion
By systematically addressing these areas, you can significantly enhance your server's performance, reliability, and security. Regular monitoring, updates, and proactive maintenance are key to maintaining optimal server performance over time. You can check more at Netseg.me.
0 notes
Text
Habilitar Gzip en Apache
Habilitar Gzip en Apache. GNU ZIP, más conocido como gzip. Es el compresor por excelencia de cualquier sitio web que se precie. Seguro que te suena la regla mod_deflate de tu htaccess, también es posible que cuando analizas tu sitio web en las herramientas Gtmetrix o pagespeed de google te indiquen que tienes recursos sin comprimir. En ese momento tu piensas... ¿como puede ser?, tengo el mod_deflate en mi archivo htaccess. Tranquilo, lo que pasa es que no tienes configurada la regla en tu servidor. De todas formas antes de comenzar quiero decir que existen otras alternativas a Gzip, pero no vale la pena ni que las pruebes (de momento), hoy en día Gzip es el rey de la compresión web. La verdad es que es un tema bastante simple, no quiero perder más tiempo con esto. Vamos directamente a la solución.
Habilitar Gzip en Apache
Lo primero que debes hacer es asegurarte que el modulo deflate esta activado en Apache. httpd -M | grep deflate ejemplo de salida con el modulo habilitado... # httpd -M | grep deflate deflate_module (shared) Creamos el archivo deflate.conf en /etc/httpd/conf.d. nano /etc/httpd/conf.d/deflate.conf Copia y pega lo siguiente: # Compress HTML, CSS, JavaScript, Text, XML and fonts AddOutputFilterByType DEFLATE application/javascript AddOutputFilterByType DEFLATE application/rss+xml AddOutputFilterByType DEFLATE application/vnd.ms-fontobject AddOutputFilterByType DEFLATE application/x-font AddOutputFilterByType DEFLATE application/x-font-opentype AddOutputFilterByType DEFLATE application/x-font-otf AddOutputFilterByType DEFLATE application/x-font-truetype AddOutputFilterByType DEFLATE application/x-font-ttf AddOutputFilterByType DEFLATE application/x-javascript AddOutputFilterByType DEFLATE application/xhtml+xml AddOutputFilterByType DEFLATE application/xml AddOutputFilterByType DEFLATE font/opentype AddOutputFilterByType DEFLATE font/otf AddOutputFilterByType DEFLATE font/ttf AddOutputFilterByType DEFLATE image/svg+xml AddOutputFilterByType DEFLATE image/x-icon AddOutputFilterByType DEFLATE text/css AddOutputFilterByType DEFLATE text/html AddOutputFilterByType DEFLATE text/javascript AddOutputFilterByType DEFLATE text/plain AddOutputFilterByType DEFLATE text/xml # Remove browser bugs (only needed for really old browsers) BrowserMatch ^Mozilla/4 gzip-only-text/html BrowserMatch ^Mozilla/4.0 no-gzip BrowserMatch \bMSIE !no-gzip !gzip-only-text/html Header append Vary User-Agent Guarda el archivo y cierra el editor. Reinicia el servicio. service httpd restart Ya lo tienes habilitado. En el próximo articulo veremos como hacer lo mismo en Nginx. Canales de Telegram: Canal SoloLinux – Canal SoloWordpress Espero que este articulo te sea de utilidad, puedes ayudarnos a mantener el servidor con una donación (paypal), o también colaborar con el simple gesto de compartir nuestros artículos en tu sitio web, blog, foro o redes sociales. Read the full article
#/etc/httpd/conf.d#Apache#archivodeflate.conf#compresiónweb#GNU ZIP#gzip#gzipenapache#habilirargzip#mod_deflate#modulodeflate#pagespeeddegoogle#reglamod_deflate
0 notes
Photo
Gzip Etkinleştirme ile Site Hızlandırma
Gzip, genelde SEO uzmanlarının Page Speed testlerinde “Gzip sıkıştırmasını etkinleştir” hatası ile karşına çıkan, bilenler için kolay bilmeyenlerin ise başını fazlasıyla karıştıran bir terimdir. Bu sorun kullanılan hosting paketinizde sıkıştırmasının etkin olmamasından kaynaklanır. Çözümü basit olan bu sorunu çözmeniz durumunda web sitenizin hızı yüksek oranda artacaktır. Özellikle WordPress siteleri hızlandırmak için yapılması gereken ilk işlemlerden […]
https://www.seocu.org/gzip-etkinlestirme/
#Cpanel#GNU Zip#Google Page Speed Test#GTMetrix#Gzip#Gzip Faydası#GZIP Sıkıştırma Etkin Mi?#İç Seo#Mod_Deflate#Nasıl Yapılır?#Page Speed#Php.ini#Seo#Site Hızlandırma#Teknik Seo#Tüm İçeriği Sıkıştırma
0 notes
Photo
This mod to hurry up Magento can solely work if mod_deflate apache module is already put in on your server. facultative output compression compresses text, CSS and JavaScript before it's sent to the browser. This leads to a smaller transfer size of all the parts for the browser, speed up magento site. To change output compression, notice the subsequent lines in you .htaccess file and simply uncomment the suitable lines, which is able to finally appear as if following:
1 note
·
View note
Photo
https://www.wpplatformhelp.com/wordpress-tutorials-by-wp-learning-lab/deflate-compression-module-is-a-quick-way-to-improve-wordpress-site-speed-using-htaccess/
Deflate Compression Module Is A Quick Way To Improve WordPress Site Speed Using htaccess
youtube
Grab Your Free 17-Point WordPress Pre-Launch PDF Checklist: https://wplearninglab.com/17-point-wp-pre-launch-checklist-optin-yt/?utm_source=YouTube_Video&utm_medium=Description_Link&utm_term=Description_Link&utm_campaign=YouTube
Deflate Compression Module Is A Quick Way To Improve WordPress Site Speed Using htaccess https://youtu.be/Mpf9fbMu96Y
Grab your free 17-Point WordPress Pre-Launch PDF Checklist: http://vid.io/xqRL
Delfate compression is similar to GZIP compression. It compresses the HTML of your site content which is then decompressed by the browser. This equates to faster page load times.
HTTP Compression Test: http://www.whatsmyip.org/http-compression-test/
Deflate Compression code: https://wplearninglab.com/mod-deflate-compression/
GZIP Compression tutorial: https://www.youtube.com/watch?v=QOnouKjb8iI
Who would have thought that adding simple mod_deflate compression code to your site’s .htaccess can make such a big difference regarding your page loading speed?
Even though there are a lot of things you can do to speed up your site, this method of WordPress page optimization is both simple and effective. Here’s how you can optimize your page using mod_deflate compression in a few easy steps.
You can either watch the detailed video tutorial below or scroll below that to read the image/text version of the tutorial.
https://www.youtube.com/embed/Mpf9fbMu96Y
Mod_deflate Compression Testing The Domain Name
For starters, you’ll need to check whether your site needs compression. There are numerous ways to check that, but for the purpose of this article we will this HTTP compression site http://www.whatsmyip.org/http-compression-test/.
On that page type the domain name inside the input box and click on “Test”.
Inspect The Results
After testing, you’ll need to analyze the results you got. The test will show you the page size, possible compressed page size and the percentage of potential savings.
If the results suggest that compression will be helpful, move on to the next step.
Finding The .htaccess File
Before accessing the .htaccess file, make sure that all the files in your cPanel file manager are visible.
To do so, you must enter your cPanel File Manager.
If a dialogue box appears and there’s a “show hidden files” checkbox, verify that it is checked.
If you do not see the dialogue box, you may be able to access the settings menu in the upper right corner of the File Manager. In there check the box to show the hidden files.
Paste The Code Inside The Code Editor
Without disturbing existing code in the file, just paste in the code below.
The contents of your .htaccess file inside the code editor should look something like this.
Now click on “Save Changes”.
Verifying Compression Is Working
Finally, go back to the URL from the first step: http://www.whatsmyip.org/http-compression-test/ and check whether your site is now compressed.
If you see a green check mark like in the screenshot, congratulations. Your site is now being served compressed which makes it load faster.
Read the full blog post here: https://wplearninglab.com/mod-deflate-compression/
I hope this information helps you! If you have any questions leave a comment below or ping me @WPLearningLab on Twitter.
————–
If you want more excellent WordPress information check out our website where we post WordPress tutorials daily.
https://wplearninglab.com/
Connect with us:
WP Learning Lab Channel: http://www.youtube.com/subscription_center?add_user=wplearninglab
Facebook: https://www.facebook.com/wplearninglab
Twitter: https://twitter.com/WPLearningLab
Google Plus: http://google.com/+Wplearninglab
Pinterest: http://www.pinterest.com/wplearninglab/ source
0 notes
Text
CMS Comparison: WordPress vs Drupal vs TYPO3
CMS became a word in the web development industry because of its benefits.
CMS stands for Content Management System. It is a term and has not been endorsed with a solid definition. A CMS can have multiple meanings rely on the scenarios and the person or project objectives.
CMS Comparison: WordPress vs Drupal vs TYPO3
1) WordPress
With approximately 18 million installations, WordPress is the most widely used open source CMS worldwide. WordPress holds more than 23% share across the internet as of August 2014 (and the number is only growing). Moreover, WordPress CMS is one of the finest frameworks – loved by both – developers and end users. With a staggering number of exciting plug-ins and extensions, developers can create robust content management system using WordPress.
Facts
18,000 extensions and over 14,000 free design templates
“Five-minute installation” via Wizard
Search engine friendly URLs
Publishing and management tools for mobile solutions
System requirements for WordPress 4.9.4
Web Server: Each server with PHP and MySQL / MariaDB support (Recommended: Apache)
Middleware: PHP 7.2 or higher
Database: MySQL 5.6 or higher / MariaDB 10.0 or higher
Hardware: The developer proposes a PHP memory limit of 32 MB or more
Other recommendations: For HTTPS support/search engine friendly URLs, Apache module requires mod_rewrite.
2) Drupal
Initially, Modular CMS Drupal was developed as a student community solution, but now it is available as a fully open source CMS. The module also enhances or we can say improves the software which comes with a very lean basic installation. Today, the basic strength of the project lies in its community. Many basic modules have already Web 2.0 and community work such as weblog, forums and tag cloud.
Facts
Very flexible, modular layout
A slim basic installation with more than 36,000 extension modules
Focus on social publishing and community projects
More than 1100 distributions as a complete solution for typical applications
System requirements for Drupal 8
Web Server: Apache, Nginx, MS IIS, or any other web server with PHP support
Middleware: PHP 5.5.9 or higher
Database: MySQL 5.5.3, MariaDB 5.5.20, Percona server 5.5.8 or higher (PDO requires an InnoDB-compatible storage engine); PostgreSQL 9.1.2 or higher (with PDO); SQLite 3.7.11 or higher
3) TYPO3
TYPO3 is the third one to use open source CMS. A software project is an enterprise management system and is continuously updated and kept continuously by a team of experienced developers. TYPO3 is a free and open-source Web content management system written in PHP. It is released under the GNU General Public License.
Facts
Enterprise content management system
Huge range of functions
Extensive integrated rights management
System requirements for TYPO3 CMS 9.1
Web Server: Apache (recommended), MS IIS, NGINX
Middleware: PHP 7.2 or higher
Database: MySQL 5.5 or higher / MS SQL Server 2000 / PostgreSQL 7.x and 8.x / Oracle 8, 9, 10, and 11 / Firebird 1.5.2
Hardware: At least 256 MB RAM
Other recommendations: GraphicsMagick or ImageMagick; GDlib; Freetype; If using an Apache server: mod_gzip, mod_deflate, mod_rewrite; PHP cache (for example APCu, PHP accelerator, OPcache, or Zend accelerator); individual extensions may require additional software.
How Let’s Nurture can help?
Let’s Nurture is an elite CMS Development company that provides open source CMS with all the latest features that are ensured to deliver quick ROI. We provide enriched and robust CMS to scale up and incur very low maintenance cost. Our CMS Development Team provides a complete manual that guides you in the initial phase how to use the CMS to manage every facet of your website without paying more money to webmasters.
If you have to get some answers concerning cms or have any request; empathetically, get in touch with us.
0 notes
Text
WordPress Gzip sıkıştırma Nasıl Yapılır?
Sitelerde, en önemli dikkat edilmesi gereken nokta tasarım ve işlevden sonra hızdır. Ziyaretçi olarak kendinizi düşünmeniz gerekirse hızlı olan bir siteye girince daha çok sayfa dolaşırlar. Eğer siteniz yavaşsa, ziyaretçiler görmek istedikleri bu sayfayı gördükten sonra diğer bir sayfaya geçmek istemezler çünkü site yavaştır. WordPress’in GZippy eklentisini sitenize kurup, hız sorununu giderirsiniz. GZippy amacı ilk olarak, wordpress sitenin tüm sayfalarının html yapısının sıkıştırılmasını sağlamaktır. Bu sıkıştırma, %91′e kadar çıkabilir. WordPress, internet sitelerinde çok daha hızlı bir biçimde açılmasını sağlıyor. Gzippy eklentisini de etkinleştirdikten sonra sıkıştırma olayı otomatik olarak başlamaktadır. Ekstra ayar yapmamıza gerek kalmaz. WordPress Gzip Kurulumu WordPress kullanım amacı belirttiğimiz gibi sitenizde hızlı yükleme süresi sağlamak için sayfanın boyutunu azaltmak oldukça önemlidir. Bu, 1 saniyenin altına inen herhangi bir siteyle açılmayan diğer bir sitenin arasındaki farkı gösterebilir. GZIP sıkıştırmasını etkinleştirmek sizin web sayfanızın boyutunu azaltmanıza yardımcı olabilir. En baştaki işimiz tüm eklentilerde olduğu şekilde eklentiyi indirip, WinRAR sıkıştırma programı aracılığıyla içindeki klasörü sıkıştırılmış RAR’dan çıkarıyoruz. Çıkan bu klasörü, istenilen bir FTP yöneticisi ile siteye bağlanıp …/wp-content/plugins dizinine göndeririz. Admin panel sayfasından Eklentiler sayfasına girip eklentiyi aktifleştiriyoruz. Gzippy Ayarları Yapmak WordPress GZIP’i etkinleştirmenin daha başka çeşitli yolları var. Bunlardan biri sitenizde GZIP özelliğini desteklemesi gereken bir önbellek eklentisi kurmaktır. Şimdi piyasada bulunan çoğu önbellek eklentisi mesela WP Super Cache, WP Total Cache, WP Rocket gibi söz konusu özelliği destekliyor ise ve mod_deflate modülünü de kullanarak otomatik bir şekilde GZIP’ın çalışmasını sağlıyorsa kullanılabilir. Bunun yanı sıra sadece GZIP özelliğini aktif etmek için kullanılan bir WP eklentileri de bulunur. Bunlardan bir tanesi ise GZIP compression adlı eklentidir. Kurulumu basit olan; eklenti ekle kısmından arayarak buluyorsunuz, yükle ve etkinleştir dedikten sonra diğer işlem GZIP’i etkinleştir diyorsunuz, gerisini kendi halleder. Yalnız burada dikkat edilmesi gereken sunucunuz dosya izinleri değişikse sorun çıkabilir. Read the full article
#ckdijital#çözüm#dijital#eticaret#facebook#instagram#instagramuzman#internet#is#istanbul#problem#rapor#sorungider#sosyalmedya#twitter#uzman
0 notes
Text
How to increase page speed to improve SEO results
Page speed has been a part of Google’s search ranking algorithms for quite some time, but it’s been entirely focused on desktop searches until recently when Google began using page speed as a ranking factor for mobile searches as well.
Have you checked your page speed scores lately?
How do your speeds match up against your competition?
If your pages are loading slower than competitors, there’s a chance you’re taking a hit in the SERPs. While relevance of a page carries much more weight than page speed, it’s still important to ensure your pages are loading fast for users and search engines.
Here are 5 ways to increase page speed and improve SEO results.
Compress images
Large image files can have a significant negative impact on page speed performance. Images often represent the largest portion of bytes when downloading a page. This is why optimizing images generally returns the biggest improvement in speed performance. Compressing your images using an image compression tool will reduce their file size leading to faster loading pages for both users and search engines, which in turn will have a positive impact on your organic search rankings.
Leverage browser caching
Web browsers cache quite a bit of information, including images, JavaScript files and stylesheets. The benefit is that when visitors revisit your site, the browser doesn’t have to reload the whole page. If your server does not include caching headers or if resources are only cached for a short period of time, then pages on your site will load slower because browsers must reload all of this information.
Google recommends setting a minimum cache time of one week (and preferably up to one year) for static assets, or assets that change infrequently. So, make sure you work with your web developer to ensure caching is setup for optimal page speed performance.
Decrease server response time
There are numerous potential factors that may slow down the response of your server: slow database queries, slow routing, frameworks, libraries, slow application logic, or insufficient memory. All these factors should be taken into consideration when trying to improve your server’s response time.
The most favorable server response time is under 200ms. SEO marketers should work with their website hosting provider to reduce server response time and increase page speed performance.
Enable Gzip compression
Your pages will load slower if your site has compressible resources that are served without Gzip compression. Gzip, a software application for file compression, should be utilized to reduce the size of files on your site such as CSS, HTML, and JavaScript (but not images).
You will need to determine which type of server your site runs on before enabling Gzip compression as each server requires a unique configuration, for example:
Apache: mod_deflate
IIS: Configure HTTP Compression
Nginx: ngx_http_gzip_module
Again, your hosting provider can help you enable Gzip compression accordingly. You’d be surprised how much faster your pages load by having Gzip implemented.
Avoid multiple landing page redirects
Having more than one redirect from a given URL to the final landing page can slow page load time. Redirects prompt an additional HTTP request-response which can delay page rendering. SEO Marketers should minimize the number of redirects to improve page speed. Check your redirects and make sure you don’t have redundant redirects that could be slowing load time.
Conclusion
SEO marketers must be analyzing and improving page speed. A great place to start is compressing images, utilizing caching, reducing server response time, enabling file compression, and removing multiple/redundant redirects.
I urge marketers to periodically use Google’s Page Speed Insights Tool to check your load time and compare your website to competitors’ sites. The tool also provides specific, recommended optimizations to increase your site’s page speed performance.
As Google continues to favor fast-loading websites it’s crucial that SEO Experts take necessary steps to ensure your site’s pages are meeting (and beating) Google’s expectations. Today, improving page speed is an essential aspect of any successful SEO Program.
The post How to increase page speed to improve SEO results appeared first on Search Engine Watch.
from Digtal Marketing News https://searchenginewatch.com/2018/12/07/increase-page-speed-seo-results-116310/
0 notes
Text
How to increase page speed to improve SEO results
Page speed has been a part of Google’s search ranking algorithms for quite some time, but it’s been entirely focused on desktop searches until recently when Google began using page speed as a ranking factor for mobile searches as well.
Have you checked your page speed scores lately?
How do your speeds match up against your competition?
If your pages are loading slower than competitors, there’s a chance you’re taking a hit in the SERPs. While relevance of a page carries much more weight than page speed, it’s still important to ensure your pages are loading fast for users and search engines.
Here are 5 ways to increase page speed and improve SEO results.
Compress images
Large image files can have a significant negative impact on page speed performance. Images often represent the largest portion of bytes when downloading a page. This is why optimizing images generally returns the biggest improvement in speed performance. Compressing your images using an image compression tool will reduce their file size leading to faster loading pages for both users and search engines, which in turn will have a positive impact on your organic search rankings.
Leverage browser caching
Web browsers cache quite a bit of information, including images, JavaScript files and stylesheets. The benefit is that when visitors revisit your site, the browser doesn’t have to reload the whole page. If your server does not include caching headers or if resources are only cached for a short period of time, then pages on your site will load slower because browsers must reload all of this information.
Google recommends setting a minimum cache time of one week (and preferably up to one year) for static assets, or assets that change infrequently. So, make sure you work with your web developer to ensure caching is setup for optimal page speed performance.
Decrease server response time
There are numerous potential factors that may slow down the response of your server: slow database queries, slow routing, frameworks, libraries, slow application logic, or insufficient memory. All these factors should be taken into consideration when trying to improve your server’s response time.
The most favorable server response time is under 200ms. SEO marketers should work with their website hosting provider to reduce server response time and increase page speed performance.
Enable Gzip compression
Your pages will load slower if your site has compressible resources that are served without Gzip compression. Gzip, a software application for file compression, should be utilized to reduce the size of files on your site such as CSS, HTML, and JavaScript (but not images).
You will need to determine which type of server your site runs on before enabling Gzip compression as each server requires a unique configuration, for example:
Apache: mod_deflate
IIS: Configure HTTP Compression
Nginx: ngx_http_gzip_module
Again, your hosting provider can help you enable Gzip compression accordingly. You’d be surprised how much faster your pages load by having Gzip implemented.
Avoid multiple landing page redirects
Having more than one redirect from a given URL to the final landing page can slow page load time. Redirects prompt an additional HTTP request-response which can delay page rendering. SEO Marketers should minimize the number of redirects to improve page speed. Check your redirects and make sure you don’t have redundant redirects that could be slowing load time.
Conclusion
SEO marketers must be analyzing and improving page speed. A great place to start is compressing images, utilizing caching, reducing server response time, enabling file compression, and removing multiple/redundant redirects.
I urge marketers to periodically use Google’s Page Speed Insights Tool to check your load time and compare your website to competitors’ sites. The tool also provides specific, recommended optimizations to increase your site’s page speed performance.
As Google continues to favor fast-loading websites it’s crucial that SEO Experts take necessary steps to ensure your site’s pages are meeting (and beating) Google’s expectations. Today, improving page speed is an essential aspect of any successful SEO Program.
The post How to increase page speed to improve SEO results appeared first on Search Engine Watch.
from Digtal Marketing News https://searchenginewatch.com/2018/12/07/increase-page-speed-seo-results-116310/
0 notes
Text
How to increase page speed to improve SEO results
Page speed has been a part of Google’s search ranking algorithms for quite some time, but it’s been entirely focused on desktop searches until recently when Google began using page speed as a ranking factor for mobile searches as well.
Have you checked your page speed scores lately?
How do your speeds match up against your competition?
If your pages are loading slower than competitors, there’s a chance you’re taking a hit in the SERPs. While relevance of a page carries much more weight than page speed, it’s still important to ensure your pages are loading fast for users and search engines.
Here are 5 ways to increase page speed and improve SEO results.
Compress images
Large image files can have a significant negative impact on page speed performance. Images often represent the largest portion of bytes when downloading a page. This is why optimizing images generally returns the biggest improvement in speed performance. Compressing your images using an image compression tool will reduce their file size leading to faster loading pages for both users and search engines, which in turn will have a positive impact on your organic search rankings.
Leverage browser caching
Web browsers cache quite a bit of information, including images, JavaScript files and stylesheets. The benefit is that when visitors revisit your site, the browser doesn’t have to reload the whole page. If your server does not include caching headers or if resources are only cached for a short period of time, then pages on your site will load slower because browsers must reload all of this information.
Google recommends setting a minimum cache time of one week (and preferably up to one year) for static assets, or assets that change infrequently. So, make sure you work with your web developer to ensure caching is setup for optimal page speed performance.
Decrease server response time
There are numerous potential factors that may slow down the response of your server: slow database queries, slow routing, frameworks, libraries, slow application logic, or insufficient memory. All these factors should be taken into consideration when trying to improve your server’s response time.
The most favorable server response time is under 200ms. SEO marketers should work with their website hosting provider to reduce server response time and increase page speed performance.
Enable Gzip compression
Your pages will load slower if your site has compressible resources that are served without Gzip compression. Gzip, a software application for file compression, should be utilized to reduce the size of files on your site such as CSS, HTML, and JavaScript (but not images).
You will need to determine which type of server your site runs on before enabling Gzip compression as each server requires a unique configuration, for example:
Apache: mod_deflate
IIS: Configure HTTP Compression
Nginx: ngx_http_gzip_module
Again, your hosting provider can help you enable Gzip compression accordingly. You’d be surprised how much faster your pages load by having Gzip implemented.
Avoid multiple landing page redirects
Having more than one redirect from a given URL to the final landing page can slow page load time. Redirects prompt an additional HTTP request-response which can delay page rendering. SEO Marketers should minimize the number of redirects to improve page speed. Check your redirects and make sure you don’t have redundant redirects that could be slowing load time.
Conclusion
SEO marketers must be analyzing and improving page speed. A great place to start is compressing images, utilizing caching, reducing server response time, enabling file compression, and removing multiple/redundant redirects.
I urge marketers to periodically use Google’s Page Speed Insights Tool to check your load time and compare your website to competitors’ sites. The tool also provides specific, recommended optimizations to increase your site’s page speed performance.
As Google continues to favor fast-loading websites it’s crucial that SEO Experts take necessary steps to ensure your site’s pages are meeting (and beating) Google’s expectations. Today, improving page speed is an essential aspect of any successful SEO Program.
The post How to increase page speed to improve SEO results appeared first on Search Engine Watch.
from Search Engine Watch https://searchenginewatch.com/2018/12/07/increase-page-speed-seo-results-116310/
0 notes
Text
Cara Mengaktifkan Gzip Compression di Apache
Cara Mengaktifkan Gzip Compression di Apache
Module mod_deflate akan membuat output ter compress sebelum di kirim dan di terima oleh user melalui jaringan. mod_deflate adalah pengganti dari mod_gzip yang sudah digunakan dengan versi Apache yang lebih lama.
Cara Mengaktifkan Gzip Compression di Apache
Pada dasarnya, module mod_deflate sudah ada di Apache. untuk meyakinkan module ini aktif, lihat di baris dalam file Apache configuration.
Load…
View On WordPress
0 notes
Text
Linux Hosting Seçiminde Neden Myhostcum?
Linux Hosting konusunda gerçekten ciddi boyutta rekabet var. Hosting firmalarının avantajları da var dezavantajları da var. Biz de kendi avantajlarımızdan bahsedeceğiz.
Biz donanım ve yazılımın %100 uyumundan yanayız. Yani sağlam optimizasyon ile donanımdan en yüksek performansı alabiliriz. Bizde %100 demeyelim de %99 bu konuda iddialı olduğumuzu söylüyor ve aşağıda ispat edeceğiz.
Ücretli Yazılımlar yerine ücretsiz olanları kullanmak
Litespeed, cloudlinux gibi hem güvenlik hemde performans sağlayan yazılımlar ücretlidir. Günümüzdeki döviz kurunun artmasından dolayı maliyet artmaktadır. Bizim amacımız açık kaynak kodlu ve ücretsiz olan yazılımlar ile en iyi performans ve güvenliği elde edebilmek ve fiyatımızı uygun tutabilmektir.
1. Nginx
Apache ve nginx sağlam şekilde optimiza edilirse gerçekte çok sağlam verim alınabiliyor. Mesela biz apache sistemini güzelce optimize edip php-fpm sistemini aktif ettik. Tabii ki opcache sistemini aktif ettiğimiz için cache sistemi gibi bir sistem ortaya çıkıyor ve siteler daha hızlı şekilde ramdan kullanılabiliyor. Nginx sistemini ters proxy olarak kullanıp conf dosyasını sağlam şekilde düzenledik. Bunun güzel yönleri ise dinamik sayfaları belleğe alıp mikrocache dediğimiz sistem aktif oluyor. Bu da yine sunucunun zorlanması ortadan kaldırıyor.
Tabii ki bununla bitmiyor. Eski adıyla mod_deflate sistemi yani gzip olayını aktif ettiğimiz için sıkıştırma olayı daha sağlam oluyor ve pagespeed değerleri daha yüksek çıkmasına sebep oluyor. Buda arama motorları için olumlu etken.
Burada kalmayıp sitatik sayfaların cache süresi 30 dk olarak ayarladık. Devamlı sayfa derleme olayına girilmiyor. Buraya dikkat çekmek istiyorum. WordPress sistemlerinden cache sistemi (FASTEST CACHE) kurulumunda ise nginx sayfaları statik olarak algıladığı için dinamik sayfaları statik sayfa statüsüne göre cacheleme yapıyor. E tabii ki buda ekstra performans ve az sunucu yükü demek oluyor.
2. PHP-FPM
Cloudlinux’un yerine tutmaz ama bazı sınırlamalarda kullanılabilme yetkisine sahip. Cpanel’e entegre olarak gelen sistem gerçekten çok kullanışlı. Müşterilerin çoğu cpu oranı var mı gibi sorular sormaktadır. Cpu oranı yok. Sadece Childiren yani php derleme de sınırımız var. O da sitenin yavaş açılması değil sırayla açılmasını sağlamaktadır.
Uygun Fiyat
Linux Hosting alırken en önemli konuların başında gelmektedir. Maliyet! Ücretli yazılımlar yerine ücretsiz olanları kullanmak. %30 bariz şekilde fiyat farkı çıkıyor ortaya. Bu da uygun fiyata kaliteli hizmeti almak demek.
Yazımızı kısaca toparlamak gerekirsek
Donanım – yazılım uyumluluğu
mümkün olduğunca ücretsiz yazılım
sağlam optimizasyon
ana maddede toparlayabiliriz. Eğer Linux hosting hosting almak isterseniz Yıllık linux hosting paketlerimiz ve Aylık linux hosting paketlerimizi görmek isterseniz sitemizi ziyaret edebilirsiniz.
Linux Hosting Seçiminde Neden Myhostcum?
0 notes
Text
The Low Hanging Fruit of Web Performance
New Post has been published on https://britishdigitalmarketingnews.com/the-low-hanging-fruit-of-web-performance/
The Low Hanging Fruit of Web Performance
There is so much to know about making websites fast. It’s rather incredible. Things like understanding servers and networks, how browsers parse things and make decisions, efficient coding choices, and file format nuances make being a performance expert a full-time career in itself.
But you don’t have to be an expert to care about web performance nor be an expert to start making changes to your websites to make them faster. Even total beginners to the web industry have the power to make significant performance increases to the sites they work on.
Perhaps you’ve heard this one?
If you save the length of an array first rather than calculating on each iteration of a for loop, it’s faster:
// this is faster var l = arr.length; for (var x = 0; x < l; x++) dosmth = arr[x]; // than this for (var x = 0; x < arr.length; x++) dosmth = arr[x];
That’s exactly what I’m not talking about. Haha. Sorry.
I want to talk about low hanging fruit. Easy changes that have big impact on web performance.
I have some of my own ideas. As a front-end developer and someone who thinks the web is a pretty darn great thing, I’m into any idea that makes it better. A few years back I did a whole talk on 10 things you can do to make your site faster, all of which are pretty low-hanging fruit.
But more recently, I asked on Twitter, and lots of people had some ideas of their own.
What are the LOWEST hanging fruit of web performance? Nothing fancy, anyone can do, big impact. Gzip. Optimize stuff. Reduce requests… What are other big ones? — Chris Coyier (@chriscoyier) August 17, 2018
Lemme squish it all together and make a list! Remember this isn’t a comprehensive list of performance-increasing tactics. The requisites to be on this list are that they are fairly easy to do and that have big performance returns.
1) Reduce Requests
This one is my favorite. Anytime I can rip something off of a page and not really sacrifice anything, it feels great. Are there some CSS files you can combine? Tracking scripts you can remove? Sharing buttons that could be just simple links?
Dave Rupert recommends keeping an inventory of all the stuff on your pages so you know why it’s there and what it’s purpose is.
ImageAlpha + ImageOptim (Mac) / RIOT (Win) before upload SVGOMG before upload Keep an inventory of wtf is being added and why
— Dave Rupert (@davatron5000) August 17, 2018
You should also consider the concept of a performance budget. A performance budget might say: you have X requests for Y total file size and Z seconds of load time and nobody can do anything to exceed them. Make it part of the culture around your site!
2) Optimize Assets
Your images can probably be a lot smaller in file size than they already are, without losing any or much quality. Download an app like ImageOptim and drop images onto it before you use them on the web.
The same concept applies to all sorts of other file types. Rather than linking up the “raw” JavaScript that you write by hand, it should be run through a minifier to reduce its file size. This does stuff like remove whitespace and even fancy stuff like rewrite function names and calls to shorter versions. Same with CSS, it should be minified. There are loads of ways to do this that any build process can handle. For one example, here’s me using CodeKit and making sure the output of my SCSS is compressed:
For SVG files, check out SVGOMG!
Google performance expert Das Surma says compressing/optimizing images is the lowest hanging fruit of all for web performance. For images and video specifically, I’d also recommend checking out services like Cloudinary or Imgix which specialize in optimizing and serving images in super performant ways.
3) Make sure you’re gzipping
As a test, open your Network tab in DevTools and pick a CSS file. Look under the Response Headers and see if the content-encoding is gzip.
If it’s not, there are massive savings you could be having by just making sure gzip encoding is turned on on your server. Your host should have information about this for you. Here on MediaTemple, on an Apache server, here’s some info for that. It’s about making sure mod_deflate is on, which does the gzipping.
You might even investigate Brotli, which can be ever better than Gzip, and I notice is supported here on MediaTemple through the Securi firewall.
4) Make sure you’re browser caching
See that second arrow in the screenshot above? That points to an expires date for that CSS file. Notice it expires in the year 2037. That means the browser will hang onto that file essentially forever and not need to re-download it when needed again. That’s a massive performance booster. Need to change the file? Change its name! style.css?v=16.4
Speaking of caching… the general concept of caching is a massive part of web performance low hanging fruit. Your web host can probably make recommendations here. For example, perhaps they can flip on nginx reverse caching for you. Or if you’re running something like a WordPress site, perhaps you can toss on a plugin like W3 Total Cache and reap the rewards from that.
5) Use a CDN
Like Tim Murtaugh says… set up a CDN.
Content Delivery Networks (CDNs) are for serving your flat files (like images, CSS, and JavaScript) from super fast servers that are specifically tuned for that job (for example, they are “cookieless” which saves some network data overhead). Plus they serve those files from servers that are geographically as close as possible to the user requesting that file. Big gains!
This is low hanging fruit as it’s generally a one-time setup and it’ll benefit you forever. Look into setting up Cloudflare for your site, or something like Stack Path or KeyCDN.
Media Temple offers a nifty a CDN and Web Application Firewall, all-in-one.
6) Lazy Load and Defer Loading of Things
The idea of lazing loading is that you don’t request the asset (like an image or video) until it’s needed. Imagine you visit a blog post that has 6 images on it, but 5 of them are down the page pretty far, and you never bother to scroll down. Why request the other 5?
There are lots of techniques for lazing loading, so allow me to just link you to Jeremy Wagner’s article on Google Fundamentals which covers the concept.
The idea of deferring the loading of JavaScript is simple. There are fancy ways of doing this like code splitting, but perhaps the lowest hanging fruit is deferring the loading of a script by putting it at the bottom of the page, or literally using the defer attribute.
Just add `defer` to any script element. Takes 0.7s to implement, makes your page a gazillion times faster. Pretty good ROI if you ask me.
— Benjamin De Cock (@bdc) August 17, 2018
7) Use responsive images (or at least use reasonable sizes)
Zak Nicola says he’s hit “home runs” for local business clients by simply resizing images on their sites to reasonable sizes. They had massive 4k images being put into a 120x60px spot. Yikes. It’s more common that you’d like.
Using reasonably sized images is a quick win. Check out Dave Rupert’s 1.5x images thinking. That might be a good default for everything.
Doing a bit more, look at using responsive images, which is special HTML for your images that has the focused purpose of serving the best possible image for the situation.
<img src="small.jpg" srcset="medium.jpg 1000w, large.jpg 2000w" alt="yah">
<picture> <source srcset="examples/images/extralarge.jpg" media="(min-width: 1000px)"> <source srcset="examples/images/art-large.jpg" media="(min-width: 800px)"> <img srcset="examples/images/art-medium.jpg" alt="…"> </picture>
Also, consider stuff like using muted autoplaying videos instead of GIFs.
Animated GIFS to videos (Autoplay, muted, loop). Remove the audio track too.
— Doug Sillars (@dougsillars) August 17, 2018
8) Mind Your Fonts
Using custom web fonts can be just as much of a performance burden as the usual suspects: images and JavaScript.
Do you need them at all? If you can get away with not using any custom web fonts at all, or removing some/all of the ones you have, you’ll certainly see performance gains. Perhaps check out using a system font stack.
If you need to use them (I don’t blame you, typography is fun and gives a site a lot of life), then you’ve still got options for improving the performance of them. The lowest hanging fruit is to try out using CSS in your @font-face declarations for those custom fonts, in the form of font-display: optional; /* or swap */. With that, the custom fonts will never hold up the loading of the page, so you might experience FOUT (Flash of Unstyled Text) but never FOIT (Flash of Invisible Text). The “invisible” situation is the one that impacts web performance the most. Pages with no text are pretty useless.
As Brian P. Hogan says, that’s perceived performance as much as it is actual performance.
I’d say understanding what blocks the page from loading and what doesn’t. So, not just “actual” performance but “perceived” performance.
— Brian P. Hogan (@bphogan) August 17, 2018
If you wanna get hot and heavy with the performance of loading fonts, dig into Zach Leatherman’s Guide to Font Loading Strategies.
9) Good Hosting / HTTP2 / PHP7
There is some performance low hanging fruit in your web hosting itself. If your site has slowness issues in the form of response time being slow, perhaps it’s time to upgrade to something more powerful than shared hosting. Throwing money at a speed problem doesn’t always work and isn’t always an option, but sometimes it’s the perfect solution. And it’s definitely low hanging fruit as the effort is minimal.
Speaking of hosting, your web host can probably help you upgrade or configure your hosting to take advantage of the best technologies available.
Turn on http2 and make sure PHP is upgraded to PHP 7 (if applicable)
— Megan Zlock (@meganzlock) August 17, 2018
Ask your host about the possibility of taking advantage of HTTP/2, and if you’re running a classic CMS like WordPress or CraftCMS, getting on the very latest versions of PHP and MySQL which have had massive performance improvements in recent years.
10) Turbolinks
This Turbolinks stuff is a bit of a wild card in this list, but I like it because if it can possibly work for you, you get some increase performance with little work (again, low hanging fruit).
Have you heard of SPAs (Single Page Apps)? The whole idea there is that once the site loads, even as you click around, interact, and go to other pages of the site, the site never reloads. For example, you’re building a React site with React Router. URLs still change and all that, but the laborious process of a full page reload never happens. It’s all Ajax requests and re-rendering. Done right, very cool.
Turbolinks brings that kind of behavior to a site that wasn’t originally built that way. Rather than refresh the page, when you click a link it goes and fetches that page and re-renders what is needs to on the current page.
Resources
Source: http://mediatemple.net/blog/tips/low-hanging-fruit-web-performance/
0 notes
Text
Using Mod_PageSpeed Filters
https://lemacksmedia.com/news/08/27/using-mod_pagespeed-filters/
Using Mod_PageSpeed Filters
Mod_PageSpeed Filters
Apache Mod_PageSpeed is still currently “incubating” as you can see if you checkout the official Mod_PageSpeed site . Though it has been incubating for several years now, it’s a tool that Google very highly recommends use of for websites and web applications of all sizes.
A properly deployment and implementation can save a Developer or Programmer hours, if not days of their time tweaking and optimizing everything from image format (like jpg to webp), to minifying and prioritizing JavaScript and CSS assets. The beauty about it is that you have the option of setting filters at site level in for example the .htaccess file, or in the configuration file the server side. Some filters like minifying and image compression make sense on server side, however, if you host sites for say a real estate firm where the listings are constantly changing and updated, you’ll want to set specific image caching rules per site.
If you haven’t already, you should check out our article on how to setup Mod_PageSpeed here.
Mod_PageSpeed Filters in .htaccess
For the sake of creating an example, I have put all of the filters for Lemacks Media in the .htaccess file for now. The primary modules you will want enabled on your server are Mod_Rewrite, Mod_Deflate, Mod_Expires, and PageSpeed_Module.
In the .htaccess file it will look something like this for Mod_Rewrite
<IfModule mod_rewrite.c> RewriteEngine On RewriteBase / RewriteRule ^index\.php$ - [L] RewriteCond %REQUEST_FILENAME !-f RewriteCond %REQUEST_FILENAME !-d RewriteRule . /index.php [L] </IfModule>
Followed by Mod_Deflate
<IfModule mod_deflate.c> # Insert filters / compress text, html, javascript, css, xml: AddOutputFilterByType DEFLATE text/plain AddOutputFilterByType DEFLATE text/javascript AddOutputFilterByType DEFLATE text/html AddOutputFilterByType DEFLATE text/xml AddOutputFilterByType DEFLATE text/css AddOutputFilterByType DEFLATE text/vtt AddOutputFilterByType DEFLATE text/x-component AddOutputFilterByType DEFLATE application/xml AddOutputFilterByType DEFLATE application/xhtml+xml AddOutputFilterByType DEFLATE application/rss+xml AddOutputFilterByType DEFLATE application/js AddOutputFilterByType DEFLATE application/javascript AddOutputFilterByType DEFLATE application/x-javascript AddOutputFilterByType DEFLATE application/x-httpd-php AddOutputFilterByType DEFLATE application/x-httpd-fastphp AddOutputFilterByType DEFLATE application/atom+xml AddOutputFilterByType DEFLATE application/json AddOutputFilterByType DEFLATE application/ld+json AddOutputFilterByType DEFLATE application/vnd.ms-fontobject AddOutputFilterByType DEFLATE application/x-font-ttf AddOutputFilterByType DEFLATE application/x-web-app-manifest+json AddOutputFilterByType DEFLATE font/opentype AddOutputFilterByType DEFLATE image/svg+xml AddOutputFilterByType DEFLATE image/x-icon # Exception: Images SetEnvIfNoCase REQUEST_URI \.(?:gif|jpg|jpeg|png)$ no-gzip dont-vary # Drop problematic browsers BrowserMatch ^Mozilla/4 gzip-only-text/html BrowserMatch ^Mozilla/4\.0[678] no-gzip BrowserMatch \bMSI[E] !no-gzip !gzip-only-text/html # Make sure proxies don't deliver the wrong content <IfModule mod_headers.c> Header append Vary User-Agent env=!dont-vary </IfModule> </IfModule>
Mod_Expires
## EXPIRES CACHING ## <IfModule mod_expires.c> ExpiresActive On ExpiresDefault "access plus 1 week" ExpiresByType image/jpg "access plus 1 year" ExpiresByType image/jpeg "access plus 1 year" ExpiresByType image/gif "access plus 1 year" ExpiresByType image/png "access plus 1 year" ExpiresByType image/svg+xml "access plus 1 month" ExpiresByType text/css "access plus 1 month" ExpiresByType text/html "access plus 1 minute" ExpiresByType text/plain "access plus 1 month" ExpiresByType text/x-component "access plus 1 month" ExpiresByType text/javascript "access plus 1 month" ExpiresByType text/x-javascript "access plus 1 month" ExpiresByType application/pdf "access plus 1 month" ExpiresByType application/javascript "access plus 1 month" ExpiresByType application/x-javascript "access plus 1 month" ExpiresByType application/x-shockwave-flash "access plus 1 month" ExpiresByType image/x-icon "access plus 1 year" ExpiresByType application/json "access plus 0 seconds" ExpiresByType application/ld+json "access plus 0 seconds" ExpiresByType application/xml "access plus 0 seconds" ExpiresByType text/xml "access plus 0 seconds" ExpiresByType application/x-web-app-manifest+json "access plus 0 seconds" ExpiresByType text/cache-manifest "access plus 0 seconds" ExpiresByType audio/ogg "access plus 1 month" ExpiresByType video/mp4 "access plus 1 month" ExpiresByType video/ogg "access plus 1 month" ExpiresByType video/webm "access plus 1 month" ExpiresByType application/atom+xml "access plus 1 hour" ExpiresByType application/rss+xml "access plus 1 hour" ExpiresByType application/font-woff "access plus 1 month" ExpiresByType application/vnd.ms-fontobject "access plus 1 month" ExpiresByType application/x-font-ttf "access plus 1 month" ExpiresByType font/opentype "access plus 1 month" </IfModule> ## EXPIRES CACHING ##
And finally, PageSpeed_Module
<IfModule pagespeed_module> ModPagespeed on ModPagespeedEnableFilters rewrite_domains ModPagespeedEnableFilters rewrite_style_attributes,rewrite_css,combine_css ModPagespeedEnableFilters prioritize_critical_css ModPagespeedEnableFilters move_css_above_scripts ModPagespeedEnableFilters move_css_to_head ModPagespeedEnableFilters elide_attributes ModPagespeedEnableFilters rewrite_javascript,combine_javascript ModPagespeedEnableFilters inline_javascript ModPagespeedEnableFilters recompress_images ModPagespeedEnableFilters convert_png_to_jpeg,convert_jpeg_to_webp ModPagespeedEnableFilters collapse_whitespace,remove_comments ModPagespeedEnableFilters responsive_images,resize_images ModPagespeedEnableFilters lazyload_images ModPagespeedEnableFilters make_google_analytics_async </IfModule>
For brevity of this article, I am only going to go over some of the PageSpeed filters, the rest you can read about by visiting the Apache PageSpeed documentation site.
CSS Filters
The PageSpeed filters reqrite_style_attributes, rewrite_css, and combine_css work to minify the css sheets and any inline styling that might have been done in html rather than being added to the theme or other stylesheet itself. All of the css assets are then combined into a single stylesheet generated by the PageSpeed module and called on each time the site is rendered.
The PageSpeed filter prioritize_critical_css does just what you might imagine, it identifies css rules necessary for rendering the content on a page, inlines those rules, and defers the loading of the remaining stylesheet rules until after the page has finished loading most of the visible content the user might interact with.
The PageSpeed filters move_css_above_scripts and move_css_to_head do exactly what they say as well. They force the loading of the css assets prior to any potentially render blocking scripts that are in the head of the site.
JavaScript Filters
The PageSpeed filter inline_javascript works by inlining external JavaScript directly into the HTML, like Facebook Pixel which helps to reduce page load and render times dramatically.
The PageSpeed filter combine_javascript reduces the number of external requests made by your browser after the initial load by replacing the multiple external JavaScript files with a single file on page refresh (or until the caching has expired).
The PageSpeed filter rewrite_javascript minifies the JavaScript files by removing whitespace, extra lines, comments and more from the file.
Image Filters
The most important filter here is hands down the convert_jpeg_to_webp filter. WebP is a newer image format that is highly compressed, meaning images load faster on most devices and browsers. Browsers that do not support WebP format images are presented with the original jpg image instead. You can read more about WebP here.
Visit Lemacks Media https://lemacksmedia.com/news/08/27/using-mod_pagespeed-filters/ for updates and more content. #Apache #Google #ModPageSpeed #PageSpeed #SearchEngineOptimization #Seo #WebDevelopment #WebHosting #Webdevelopment #Webhosting
#Apache#Google#Mod PageSpeed#PageSpeed#search engine optimization#seo#Web Development#Web Hosting#webdevelopment#webhosting#How-To#Services
0 notes
Text
(素人が)本気出して、自サイトをモバイル速度対応してみる
まずは自分のサイトでどこまで落とせるかやってみよう。 ということで、やってみました。
ま、そゆことでとりあえず何も考えず、巷に転がっている対応を色々と検証含めやってしまおうていう。 ちなみに種々こういった速度対応プラグイン入れたら 「逆にクソ重くなるか、サイトの挙動がおかしくなって自分が発狂することがある」 っていうのを身をもって体験したので今回はプラグインにはほぼ頼らず(JetPackのみ)。
検証: Xサーバー プランX10 Wordpress使用 PHPバージョン7.2.6
モバイルサイトの速度をテストしましょう。 PageSpeed Insights
めずらしく!目次
色々といじる前の元の状態
1:基本中の基本、画像圧縮
2:CDN使おう、画像の遅延読み込みしよう
3:htaccess設定しようか
4:いよいよテーマファイルいじるよ。
色々といじる前の元の状態
いじる前、っていっても実は画像圧縮プラグインがすでに入っていますので、そのあたりは対応済とおもってもらえれば。
1:基本中の基本、画像圧縮
とはいえ、まだイケんじゃね?って欲を出して再度プラグインを走らせます。 この後見たら、3時間ぐらいまで残り時間増えていたのでとりあえずほったらかし。 こんなに画像数あったんかいって驚いてる。 以前圧縮かけてますけど・・・再度かけてイミあるのかどうかは不明。 本来なら、アップロード前にTinyPNGなどで圧縮をかけてからアップロードした方が一番良いと思うんですけど。 以前はやってたんですけど、面倒になっちゃいまして。
圧縮後計測⇓
逆に増えてんぞオイw誰だ圧縮したらスピードアップ!すげえとかいってるやつ!
・・・サーバー側の問題だきっとそうだそうに違いない。 圧縮しただけで他なんもしてないもん・・・・ というか、下の方いくと、何が問題か簡易的なものが見られるんですが「サーバーのレスポンス速度」とか出てるしね。 これは、レンタルサーバー借りてやっている限りどうしようもない宿命かと思います。
各レンタルサーバーの速度比較しているサイトがあったので
Webサーバーの安定性と応答速度をツールで比較(monitis)【2017年版】 ビズサバ Xサーバーは悪くない部類、多分。
2:CDN使おう、画像の遅延読み込みしよう
Jetpackに標準であります。 ONにしてたと思ったんですけどOFFになってたので再度ON。 なんでオフにしてたんだっけ・・・・。 んー。元に戻っただけだった。
3:htaccess設定しようか
��、気を取り直して次ということで
# BEGIN WordPress <IfModule mod_rewrite.c> RewriteEngine On RewriteBase / RewriteRule ^index\.php$ - [L] RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule . /index.php [L] </IfModule> # END WordPress
これを下記に変更。
# BEGIN WordPress <IfModule mod_rewrite.c> RewriteEngine On RewriteBase / RewriteRule ^index\.php$ - [L] RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule . /index.php [L] </IfModule> # END WordPress ModPagespeed On ModPagespeedEnableFilters rewrite_css ModPagespeedEnableFilters combine_css ModPagespeedEnableFilters inline_css ModPagespeedEnableFilters inline_google_font_css ModPagespeedEnableFilters rewrite_javascript ModPagespeedEnableFilters combine_javascript ModPagespeedEnableFilters inline_javascript ModPagespeedEnableFilters rewrite_images ModPagespeedEnableFilters remove_comments ModPagespeedEnableFilters collapse_whitespace ModPagespeedDisableFilters convert_jpeg_to_webp ModPagespeedDisableFilters convert_to_webp_lossless ModPagespeedMaxCombinedCssBytes -1 ModPagespeedCssInlineMaxBytes -1 ModPagespeedJsInlineMaxBytes -1 ModPagespeedMaxCombinedJsBytes -1 ModPagespeedImageRecompressionQuality 95 AddType application/vnd.ms-fontobject .eot AddType application/x-font-ttf .ttf AddType application/x-font-opentype .otf AddType application/x-font-woff .woff AddType image/svg+xml .svg AddOutputFilterByType DEFLATE text/plain AddOutputFilterByType DEFLATE text/html AddOutputFilterByType DEFLATE text/xml AddOutputFilterByType DEFLATE text/css AddOutputFilterByType DEFLATE application/xml AddOutputFilterByType DEFLATE application/xhtml+xml AddOutputFilterByType DEFLATE application/rss+xml AddOutputFilterByType DEFLATE application/javascript AddOutputFilterByType DEFLATE application/x-javascript AddOutputFilterByType DEFLATE application/x-font-ttf application/x-font-opentype image/svg+xml <ifModule mod_expires.c> ExpiresActive On ExpiresByType text/css "access plus 10 days" ExpiresByType image/gif "access plus 10 days" ExpiresByType image/jpg "access plus 10 days" ExpiresByType image/jpeg "access plus 10 days" ExpiresByType image/png "access plus 10 days" ExpiresByType image/svg "access plus 10 days" ExpiresByType application/x-javascript "access plus 10 days" ExpiresByType text/x-javascript "access plus 1 month" ExpiresByType application/javascript "access plus 1 month" ExpiresByType application/x-javascript "access plus 1 month" ExpiresByType text/js "access plus 1 month" ExpiresByType text/javascript "access plus 1 month" ExpiresByType application/x-shockwave-flash "access plus 1 month" ExpiresByType application/vnd.ms-fontobject "access plus 1 year" ExpiresByType application/x-font-ttf "access plus 1 year" ExpiresByType application/x-font-opentype "access plus 1 year" ExpiresByType application/x-font-woff "access plus 1 year" ExpiresByType image/svg+xml "access plus 1 year" </ifModule>
・・・長い。 変わらん。 つうか、時間帯によっては10秒こえてたんでやっぱサーバーだサーバーに間違いない私にはどうしようもない! だからって、 あきらめたらそこで試合終了ですよ(by安西先生)
とりあえず説明すると、最初のほうはWPの分。 WP使ってなければこの部分は不要ですね。 WP使ってる場合は# END WordPressみたいなところは消去しないように注意。
次に、ModPagespeed Onの部分。 mod_pagespeedの設定を.htaccessで変えてみよう! 福岡のホームページ制作会社・株式会社マグネッツ ちなみにサーバーによっては設定したら、逆に読み込み速度が落ちるとかあるみたい。 何がいるかどうか全くわかんね!なので上のサイト様からコピって使ってます。
AddType applicationが、うちんとこはWebフォント使ってるので設定。 mod_deflateが、コンテンツの圧縮 ExpiresActiveがキャッシュの設定 ※これ以外にssl設定してるのでリダイレクトはいってます。
なーんの効果もないってことは、これは書き方の順番が悪いのか? ということで調べてみる。 SEO Japanの掲載記事からピックアップ Web担当者Forum
1:最初は、アクセス制御。 2:次は、外部向けリダイレクト。 3:最後は、内部でのリライト。
・・・ぶっちゃけ何いってんのかわかんねえ。
素人なりに見ていくと
RewriteEngine On はアクセス制御だろ、きっとそうだろ。 ModPagespeed On AddOutputFilterByType は内部に向けた設定だと思う。 AddType application ExpiresActive On 不明・・・。 内部かなあ。キャッシュはアクセス制御なのかなあ・・・。 あとで順番入れ替えてみてみよう。 細かい部分の順番とかあるのかなあ・・・もうApachがどうとか出てきたのでお手上げ。
この時点でPagespeed Insightでちょっと見てみる。
個人的には及第点だと思うんですけど、どうでしょう。 ちなみに、キャッシュが云々~はツイッターやらGoogleアナリティクスやらFBやらそんなのが書いてあるんだけどこれはどうしようもないです。 どうしようもする方法があるなら知りたいです。
究極はつかわない・・・てことですけど、個人サイトならいざしらず、企業サイトだったらそんなわけにもいかず。 というか、こっちが良くてもTestMySiteのほうがヒドイことがあるんですがナンナンデスカネー?
4:いよいよテーマファイルいじるよ。
1:下準備
子テーマじゃなかったら子テーマにするんだぜ? 自作のテーマファイルだったらいらないけどな? (残念ながらここは自作じゃないので子テーマ使います。) 子テーマついてねえよって人は作らないといけないんだぜ? 子テーマってなに?どやって作るのっという方は下記解りやすいです。 子テーマを作ってWordPressの既存テーマをカスタマイズする方法 Webクリエイターボックス
今更説明する必要もないのかもしれませんけど、子テーマじゃないファイルを編集しないでっていうのは テーマがアップデートしたタイミングで、自分の行った編集は全部上書きされて無くなるからです。 また、バックアップとっといて上書きでいいじゃんと思うかもしれませんけど 場合によっては色々と書き換えてアップデートしてることがあるので不具合でちゃいます。
ちなみに、適当運用のツケで親テーマ使って色々やらかしているため、 急いで子テーマに変更して設定やり直してます。
2:読み込み系の遅延とか事前読込設定しよう
・dns-prefetch
先にドメインの読み込みを行って速度改善しようってやつ。 これはヘッダーに追加します。
<!DOCTYPE html> <html> <head> <link rel="dns-prefetch" href="http://hogehoge.com"> </head> <body> <img src="http://hogehoge.com/hoge.jpg"> </body> </html>
※hogehogeは見本なんで、自分のサイトに最適なものに書き換えてね。 ちなみに・・・必要なドメインがわっかんねーお!めんどくさいお!って人のために。 下記がオススメです。便利です。 ブックマークバーに入れてポチっと押すだけでコード生成してくれます。 DNS Prefetch Generator ですが、Chromeは〇ってなっているんですが、動きませんでした。 FireFoxは動きました。 コードが生成されたら、コピーして、子テーマ(無ければ作ってね)のheder.phpに張り付けるだけです。
・async
JavaScriptを非同期で読み込みます。 やり方はめっちゃ簡単で、該当するJavaScriptに追加するだけ。
<script src="http://hogehoge.com/hoge.js" async></script>
ですが、CDNで引っ張ってきたJqueryとかとは相性悪いというか使えない? たまたまですかね。 DLして使った方がよさげです。
ちなみに、今回調べていて知ったんですが、deferという設定もあるようです。 外部JavaScriptを非同期(async / defer)で読み込みレンダリングを高速化する asyncだと順序は保証しないけどこちらは順序を保証するというもの。 これなら引っ張ってきてるのでもいけるか? ちなみに・・・このブログ、設定する必要なかったんですっとばし項目です。
2:CSS圧縮
下記の
/* Theme Name: hogehoge Theme URI: http://hogehoge.jp 以下略 */
部分以外を、圧縮してしまいます。 ツールは色々とあるので、使いやすいなと思ったものでいいと思います。 CSS Minifier (スタイルシートの圧縮) Online JavaScript/CSS/HTML Compressor
あとね、CSS非同期読み込みっていう手法もあるんですけど、こっちは私なんかよくわからなくて お手本通りにやったら、逆に重くなったアホか使えねえ!だったので使ってません。
3:ダメモトで、データベースのオーバーヘッド部分掃除
最終結果
結局1秒短縮できただけで、あんまり変わらず。 というか、こっちではどうしようもない項目に関して改善しろとか出てしまっているので これ以上は正直無理・・・ あと出来る事といえば、上のスライダーなんか取っ払ってしまうとか 画像できるだけ使わないとか、いらねープラグイン消しちまえとか、そんなもんしかありません。
クッソ早くしたいんだ、アクセスや滞在時間伸ばすにはそれしかないんだ っていう概念に凝り固まって納得できないなら、AMP使うというのもテですが ・AMP用ファイル別で用意しなきゃいけない ・凝ったことは一切できない、ぶっちゃけほぼテキストだけサイトに近いことになる ・なーんか制約多い ってんではっきりいって面倒臭い。 WPのプラグインでAMP今実装はしてますけど、勝手にそっちに行かないみたいで・・・使い方わかりません。 まあそれでも、さっき計測したら5秒なんですけどね。
2秒のために、別にファイルを用意する手間が果たして必要なのか?っつう話です。 特に、受注した案件だった場合、手間増える分工数増えるわけです、同じ料金でできるわきゃないんです、 多分疎い人だ��納得してもらえない気がします、契約取った時に説明して納得してもらえればいいですね?
というか、離脱率云々確かに大事ですけど・・・うーん。
最後に
客先のサイトどーこーする前に、初めにやれよ・・て感じなんですけど・・・まあ、面倒くさくて。 本気の本気で対応するなら 正直ここら辺とか自分で解析できるようにならないと、お話にならないと思います。 張り付けてるSSがあってるのかもわからないし、何が書いてあるのかサッパリわかりません。 解るものといったら下に書いてある赤字がエラーってぐらいか。
以下愚痴。 仕事にしてんだから素人とか書くんじゃねえって感じですけど、ぶっちゃけそこまで勉強する気ないんで・・・。 色々と出来ることは増えたけど、給料が1円も上がってない時点でやる気なんて出なくて当たり前ですしねー。 滅私奉公なんて今の時代流行らないよ、っていうか、戦国時代は報酬が期待できたから滅私奉公してたわけで しょっぼい給料でそこまでやる人って、よっぽど仕事が好きな人じゃないかな。
(素人が)本気出して、自サイトをモバイル速度対応してみる was originally published on すうべにや
0 notes