<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>サイトスピード改善 | Tekito style.me</title>
	<atom:link href="https://tekito-style.me/tag/improving-site-speed/feed" rel="self" type="application/rss+xml" />
	<link>https://tekito-style.me</link>
	<description>Web×ライフハックで役立つブログメディア</description>
	<lastBuildDate>Mon, 20 Apr 2020 13:40:44 +0000</lastBuildDate>
	<language>ja</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	

<image>
	<url>https://tekito-style.me/wp-content/uploads/2019/05/cropped-th_favicon2-background-32x32.jpg</url>
	<title>サイトスピード改善 | Tekito style.me</title>
	<link>https://tekito-style.me</link>
	<width>32</width>
	<height>32</height>
</image> 
	<item>
		<title>WordPressのサイトスピード改善で実施した12の施策とスコア結果まとめ</title>
		<link>https://tekito-style.me/columns/wordpress-sitespeed</link>
		
		<dc:creator><![CDATA[やすのり]]></dc:creator>
		<pubDate>Sat, 30 Nov 2019 09:18:50 +0000</pubDate>
				<category><![CDATA[WordPress/ブログ運営]]></category>
		<category><![CDATA[Webマーケティング]]></category>
		<category><![CDATA[SEO/グロースハック]]></category>
		<category><![CDATA[WordPress]]></category>
		<category><![CDATA[WordPressプラグイン]]></category>
		<category><![CDATA[サイトスピード改善]]></category>
		<guid isPermaLink="false">https://tekito-style.me/?p=3968</guid>

					<description><![CDATA[<p>サイトスピード（ページ表示速度）とは、ユーザーがサイトを訪問したときにサイトが表示される速さのこと。 ユーザビリティやSEOにも影響を与える重要な要素で、サイトスピードが1秒から5秒まで遅くなると、直帰率が90%増加する...</p>
The post <a href="https://tekito-style.me/columns/wordpress-sitespeed">WordPressのサイトスピード改善で実施した12の施策とスコア結果まとめ</a> first appeared on <a href="https://tekito-style.me">Tekito style.me</a>.]]></description>
										<content:encoded><![CDATA[<p><!--


<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/11/th_wordpress-speed-up_1130.jpg" alt="サイトスピード改善"></p>



--><div class="voice cf l "><figure class="icon"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_th_IMG_0018_circle.jpg" class="voice_icon__img" width="150" height="150"><figcaption class="name">やすのり</figcaption></figure><div class="voicecomment">こんにちは！「Tekito style」を運営している<a href="https://twitter.com/98nasi_nori" target="_blank" rel="noopener noreferrer">やすのり（@98nasi_nori）</a>です。普段は都内でWebディレクター/マーケターなどをしています。</div></div>
<p>サイトスピード（ページ表示速度）とは、ユーザーがサイトを訪問したときにサイトが表示される速さのこと。</p>
<p>ユーザビリティやSEOにも影響を与える重要な要素で、サイトスピードが1秒から5秒まで遅くなると、直帰率が90%増加するというデータもあります。速ければ速いに越したことはありません。</p>
<p>ですが「サイトスピードが遅いのはわかってるけど、実際にどんな対策をしたらいいのか……。」と悩んでいる方も多いのかなと思います。</p>
<p>ということで今回は、<span class="fwb">WordPressサイト・ブログのスピード改善をするために僕が実施した施策を12個紹介します</span>。また実際にどれくらい改善したのか、施策ごとにスコア結果をまとめてみました。</p>
<p>スピード改善に役立つプラグインを活用しているので、初心者の方でも実施可能な施策ばかりです。これからWordPressのサイトスピードを改善したい方は、ぜひ1つの事例として参考にいただけますと幸いです。</p>
<h2>そもそもサイトスピードが遅いと何が問題なのか？</h2>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/10/th_1_sitespeed.jpg" alt="サイトスピードデータ"><br />
<span class="fs13 fcNote">Photo by <a href="https://www.thinkwithgoogle.com/data/mobile-site-speed-user-preference/" target="_blank" rel="noopener noreferrer">https://www.thinkwithgoogle.com</a></span></p>
<p>Webサイトでユーザーがイライラする要因として最も割合が高いのが、サイトスピードであると言われています。</p>
<p>Googleが示したデータでは、54%の人がサイトのロード時間が長いとフラストレーションが溜まり、<span class="fwb">モバイルサイトの場合3秒以上ロード時間がかかると半分以上の人がそのページの閲覧を止めます</span>。</p>
<blockquote><p>
	The average mobile webpage takes 15.3 seconds to fully load, and more than half of visits are abandoned if a mobile website takes more than three seconds to load.4 In retail, we see that a one-second delay in mobile load times can impact conversions by up to 20%.</p>
<p>平均的なモバイルWebページは完全にロードするのに15.3秒かかり、モバイルWebサイトでロードするのに3秒以上かかる場合、訪問者の半分以上が閲覧を放棄します。また小売業では、モバイルサイトのロード時間が1秒遅延すると、コンバージョンに最大20%まで影響することがあります。</p>
<p><a href="https://www.thinkwithgoogle.com/marketing-resources/experience-design/mobile-website-strategy/" target="_blank" class="fs13 fcNote" rel="noopener noreferrer">https://www.thinkwithgoogle.com</a></p></blockquote>
<p>サイトスピードが遅いと、直帰・離脱に繋がり、コンテンツを読んでもらえない可能性を高め、ひいてはアフィリエイトや広告のクリック率、CVRの低下にも影響します。</p>
<p>そうした背景もあり、Googleが2018年1月に「<span class="fwb">スピードアップデート</span>」を実施し、ページの表示速度が検索エンジンのランキングに影響が出ると発表されました。<span class="fwb">サイトスピードが遅いサイトは、SEOでも不利になるのです</span>。</p>
<h3>そもそもどれくらいのスピードであればいいのか？</h3>
<p>もちろんサイトスピードは速ければ速い方がベストです。現実的には<span class="fwb">1〜2秒以内</span>くらいが理想とされています。</p>
<p>サイトスピードにはページの読み込みが完了するまでの「ロード時間」と、ユーザーが感じる「表示速度」があります。どちらかというとユーザビリティへの影響が大きいのは表示速度の方で、特に最初のファーストビューが表示されるまでの時間がユーザーの直帰率などに大きな重要を与えているようです。</p>
<p>参考までにGoogle公式サイトでは、直帰率とロード時間の関係を示す以下のデータが紹介されています（※データはモバイルページのもの）。</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/10/th_2sitespeed.png" alt="サイトスピードデータ"><br />
<span class="fs13 fcNote">Photo by <a href="https://www.thinkwithgoogle.com/marketing-resources/data-measurement/mobile-page-speed-new-industry-benchmarks/" target="_blank" rel="noopener noreferrer">https://www.thinkwithgoogle.com</a></span></p>
<div class="supplement boader">
ロード時間が1 → 3秒になると…… 直帰率が32%増加<br />
ロード時間が1 → 5秒になると…… 直帰率が90%増加<br />
</div>
<p>ちなみに最速で一時期有名になったサイトは、著名人の阿部寛さんの公式サイトです。爆速過ぎて感動しますね……（笑）。<br />
<a href="http://abehiroshi.la.coocan.jp/" target="_blank" rel="noopener noreferrer">阿部寛さんの公式サイト</a></p>
<h2>サイトスピード改善の背景と改善前のデータ</h2>
<p>僕が現在利用しているWordpressの人気テーマ<a href="https://px.a8.net/svt/ejp?a8mat=35FNTT+5YCTU+3PSE+626XU" rel="nofollow">「ストーク」</a><img decoding="async" border="0" width="1" height="1" src="https://www17.a8.net/0.gif?a8mat=35FNTT+5YCTU+3PSE+626XU" alt="">は、機能やデザインに優れていますが表示速度が遅いという難点があります。</p>
<p>そもそもモバイル版サイトの流入がPC版と比較し極端に少なく、実際に平均順位も低いので、どうしてかなと思っていましたが、1つの要因としてサイトスピードも影響してそうだなと。ユーザー行動による場合はしょうがないのですが、改善できる部分は極力改善しておきたいところ。</p>
<p>参考にGoogleが提供するサイトスピード分析のツール<a href="https://developers.google.com/speed/pagespeed/insights/" target="_blank" rel="noopener noreferrer"><br />
PageSpeed Insights</a>で、「https://tekito-style.me/columns/webdesign-school-merit」の記事をチェックしてみると……</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/10/th_4_sitespeed_sp.jpg" alt="PageSpeed Insights"></p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/10/th_3_sitespeed_pc.jpg" alt="PageSpeed Insights"></p>
<div class="cbox intitle is-style-blue_box type_normal"><div class="box_title"><span class="span__box_title">検証前のサイトスピード</span></div><div class="cboxcomment">
モバイル：13<br />
デスクトップ：44<br />
</div></div>
<div class="voice cf l "><figure class="icon"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_th_IMG_0018_circle.jpg" class="voice_icon__img" width="150" height="150"><figcaption class="name">やすのり</figcaption></figure><div class="voicecomment"><span class="fwb">スコア低……（泣）。</span></div></div>
<p>デスクトップとスマフォのスコアに約3倍の開きが……。そもそもPC版も44スコアということでかなり低いです。モバイル版に至ってはもはや壊滅的ですね。できればスコア90以上は目指したいところ。悪くても80は行きたいですねー。これは改善しがいがあるな。</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/10/th_6_sitespeed_sp.jpg" alt="PageSpeed Insights"><br />
<span class="fs13 fcNote">モバイル版</span></p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/10/th_5_sitespeed_pc.jpg" alt="PageSpeed Insights"><br />
<span class="fs13 fcNote">デスクトップ版</span></p>
<p>指摘されている改善できそうな項目は、下記のような感じですね。やはり重い画像データ周りが多いです。</p>
<div class="supplement boader">
<ul>
<li>画像サイズ</li>
<li>画像フォーマット</li>
<li>画像の遅延読み込み</li>
<li>サーバーの応答時間</li>
<li>レンダリングを妨げるリソース</li>
</ul>
</div>
<p>参考までに下記のサイトスピード計測ツール<a href="https://gtmetrix.com/" target="_blank" rel="noopener noreferrer">https://gtmetrix.com/</a>でも調べてみました。</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/10/th_7_sitespeed.jpg" alt="gtmetrix.com"></p>
<div class="supplement boader">
・PageSpeed Score：57%　E<br />
（Relative Score  / The average PageSpeed score is 72%）</p>
<p>・YSlow Score　(63%)　D<br />
（The average YSlow score is 71%）</p>
<p>・Fully Loaded Time：9.8s<br />
（Relative Fully Loaded Time　The average Fully Loaded Time is 6.8s）</p>
<p>・Total Page Size　5.06MB<br />
（The average Total Page Size is 3.25MB）</p>
<p>・Requests　104<br />
（The average number of Requests is 90）<br />
</div>
<p>フルロードに9.8秒もかかっていますね……。</p>
<h2>実際にスピード改善をやってみた！施策とその結果をまとめていきます</h2>
<p>ということで実際にサイトスピード改善で効果がありそうな施策を実施してみました。結果の検証には、<a href="https://developers.google.com/speed/pagespeed/insights/" target="_blank" rel="noopener noreferrer"><br />
PageSpeed Insights</a>のスコアを利用します。</p>
<p>参考までにテストを実施した時に環境条件は下記になります。</p>
<div class="cbox intitle is-style-blue_box type_normal"><div class="box_title"><span class="span__box_title">参考：表示速度改善時の環境</span></div><div class="cboxcomment">
・サーバー：さくらサーバー<br />
・プラン：スタンダードプラン<br />
・テーマ：ストーク<br />
・WordPressバージョン：5.2.2<br />
・PHPバージョン：PHP 5.6.40 (CGI版)<br />
</div></div>
<p>またテーマによっては、導入するとエラーやバグが発生するプラグインがあります。テスト前にかならず確認しておきましょう。<br />
参考：<a href="https://open-cage.com/incompatible-plug_ins/">アルバトロス・ハミングバード・ストークテーマと相性の悪いプラグイン</a></p>
<p>※ 実施する前に、万が一に備えて必ずバックアップを取っておきましょう！バックアップについては以下のプラグインを参考にしてみてください ↓↓<br />
<div class="related_article typesimple"><a class="related_article__link no-icon" href="https://tekito-style.me/columns/wordpress-plugin-updraftplus"><figure class="eyecatch of-cover thum"><img fetchpriority="high" decoding="async" width="485" height="303" src="https://tekito-style.me/wp-content/uploads/2019/09/th_1topUpdraftPlus2-485x303.jpg" class="archives-eyecatch-image attachment-oc-post-thum wp-post-image" alt="" srcset="https://tekito-style.me/wp-content/uploads/2019/09/th_1topUpdraftPlus2-485x303.jpg 485w, https://tekito-style.me/wp-content/uploads/2019/09/th_1topUpdraftPlus2-300x188.jpg 300w, https://tekito-style.me/wp-content/uploads/2019/09/th_1topUpdraftPlus2-768x480.jpg 768w, https://tekito-style.me/wp-content/uploads/2019/09/th_1topUpdraftPlus2-1024x640.jpg 1024w, https://tekito-style.me/wp-content/uploads/2019/09/th_1topUpdraftPlus2.jpg 1200w" sizes="(max-width: 485px) 45vw, 485px" /></figure><div class="related_article__meta archives_post__meta inbox"><div class="related_article__ttl ttl"><span class="labeltext">関連記事</span>バックアップ専用プラグインUpdraftPlusの使い方・設定方法まとめ</div><time class="time__date gf undo">2022.02.22</time></div></a></div>
<h3>1. 余計なWordpressプラグインを削除する</h3>
<p>まずは簡単にすぐできるところから。<span class="fwb">プラグインは多用すると動作が重くなったりするので、不要なプラグインはどんどん削除しましょう</span>。</p>
<p>また自分で実装できそうなものはテーマを編集するなど、できればプラグインを使わないで実現する方法を模索するのも手です。プラグインを導入する場合も、同じ機能ならできる限り動作が軽いプラグインを選びましょう。</p>
<p>今回は不要なWordpressプラグインを7個前後削除しました。</p>
<h4>サイトスピード スコア結果</h4>
<div class="cbox intitle is-style-blue_box type_normal"><div class="box_title"><span class="span__box_title">スコア結果</span></div><div class="cboxcomment">
・モバイル：17<br />
・デスクトップ：33<br />
</div></div>
<p>モバイルが微妙にスコアが上がり、PCは10くらい下がりました……。まぁこれくらいは誤差の範囲ということで次に進みます。</p>
<h3>2. WordPressに溜まったゴミデータの削除</h3>
<p>WordPressに溜まった不要なデータを削除することも、サイトスピードにプラスになる場合があります。<span class="fwb">リビジョン（記事の下書きや更新前データ）やゴミ箱のデータや、使っていないタグなど</span>。</p>
<p>余分なリビジョンが溜まるとデータベースを圧迫し、サイトスピードに悪影響を与えます。</p>
<p>今回はリビジョンデータの削除・管理でおすすめなWordPressプラグイン「<a href="https://tekito-style.me/columns/wordpress-plugin-optimizerevisions">Optimize Database after Deleting Revisions</a>」を活用してみました！</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_5optimizerevisions.png" alt="Optimize Database after Deleting Revisions"></p>
<p>設定方法や使い方の詳細についてはこちらから ↓↓<br />
<div class="related_article typesimple"><a class="related_article__link no-icon" href="https://tekito-style.me/columns/wordpress-plugin-optimizerevisions"><figure class="eyecatch of-cover thum"><img loading="lazy" decoding="async" width="485" height="247" src="https://tekito-style.me/wp-content/uploads/2019/09/th_1topOptimizeDatabase-485x247.jpg" class="archives-eyecatch-image attachment-oc-post-thum wp-post-image" alt="" srcset="https://tekito-style.me/wp-content/uploads/2019/09/th_1topOptimizeDatabase-485x247.jpg 485w, https://tekito-style.me/wp-content/uploads/2019/09/th_1topOptimizeDatabase-300x153.jpg 300w, https://tekito-style.me/wp-content/uploads/2019/09/th_1topOptimizeDatabase-768x392.jpg 768w, https://tekito-style.me/wp-content/uploads/2019/09/th_1topOptimizeDatabase-1024x522.jpg 1024w, https://tekito-style.me/wp-content/uploads/2019/09/th_1topOptimizeDatabase.jpg 1200w" sizes="(max-width: 485px) 45vw, 485px" /></figure><div class="related_article__meta archives_post__meta inbox"><div class="related_article__ttl ttl"><span class="labeltext">関連記事</span>リビジョン削除のWordPressプラグインOptimize Database after Deleting Revisionsの使い方まとめ</div><time class="time__date gf undo">2020.04.20</time></div></a></div>
<p>こちらのプラグインで、<span class="fwb">57記事の645ものリビジョンデータを削除</span>してくれました。</p>
<h4>サイトスピード スコア結果</h4>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/10/th_8_sitespeed_how2_pc.jpg" alt="PageSpeed Insights"><br />
<span class="fs13 fcNote">デスクトップ版</span></p>
<div class="cbox intitle is-style-blue_box type_normal"><div class="box_title"><span class="span__box_title">スコア結果</span></div><div class="cboxcomment">
・モバイル：17<br />
・デスクトップ：63<br />
</div></div>
<p>モバイル版は先程とスコアが変わりませんが、PC版がめっちゃ早くなりましたね。読み込み速度が体感的にも早くなりました！</p>
<p>しかし何回か計測するとPCが40くらいに戻ったりで、何が正しいのやら……。怯まず先に進めます。</p>
<h3>3. 画像の負担を軽量化・最適化する</h3>
<p>今回一番サイトスピードのネックになっていそうなのが、画像周りでした。ということでまずは画像の軽量化・最適化をしていきましょう。これでどれくらい改善できるか、楽しみなところです。</p>
<p>今回は「<a href="https://tekito-style.me/columns/wordpress-plugin-eww-imageoptimizer">EWWW Image Optimizer</a>」を利用していきます。EWWW Image Optimizerは、画像を軽量化・最適化できるWordPressプラグイン。</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_14_EWWWImageOptimizer.png.jpg" alt="EWWW Image Optimizer"><br />
<span class="fs13 fcNote">photo by：<a href="https://ja.wordpress.org/plugins/ewww-image-optimizer/" target="_blank" rel="noopener noreferrer">wordpress公式サイト</a></span></p>
<p>新規で投稿される画像はもちろん、過去に投稿した画像も自動で一括圧縮してくれます。画像に保存されている不要なメタデータを削除したりと便利なプラグインなのです。</p>
<p>設定方法や使い方の詳細についてはこちらから ↓↓<br />
<div class="related_article typesimple"><a class="related_article__link no-icon" href="https://tekito-style.me/columns/wordpress-plugin-eww-imageoptimizer"><figure class="eyecatch of-cover thum"><img loading="lazy" decoding="async" width="485" height="287" src="https://tekito-style.me/wp-content/uploads/2019/09/th_0_EWWWImageOptimizer-485x287.png" class="archives-eyecatch-image attachment-oc-post-thum wp-post-image" alt="" srcset="https://tekito-style.me/wp-content/uploads/2019/09/th_0_EWWWImageOptimizer-485x287.png 485w, https://tekito-style.me/wp-content/uploads/2019/09/th_0_EWWWImageOptimizer-300x178.png 300w, https://tekito-style.me/wp-content/uploads/2019/09/th_0_EWWWImageOptimizer-768x454.png 768w, https://tekito-style.me/wp-content/uploads/2019/09/th_0_EWWWImageOptimizer.png 1014w" sizes="(max-width: 485px) 45vw, 485px" /></figure><div class="related_article__meta archives_post__meta inbox"><div class="related_article__ttl ttl"><span class="labeltext">関連記事</span>画像圧縮・最適化プラグインEWWW Image Optimizerの使い方・設定方法まとめ</div><time class="time__date gf undo">2020.04.20</time></div></a></div>
<p>結果、以下の圧縮・最適化に成功しました。</p>
<div class="supplement boader">
<ul>
<li>圧縮：25%</li>
<li>リサイズ：20%</li>
<li>削除結果：54.76 MB</li>
</ul>
</div>
<p>これまで割とこまめに1枚1枚リサイズして圧縮していたのですが、まだまだリサイズできたようですね……。</p>
<h4>サイトスピード スコア結果</h4>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/10/th_9_sitespeed_how3_SP.jpg" alt="PageSpeed Insights"><br />
<span class="fs13 fcNote">モバイル版</span></p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/10/th_10_sitespeed_how3_pc.jpg" alt="PageSpeed Insights"><br />
<span class="fs13 fcNote">デスクトップ版</span></p>
<div class="cbox intitle is-style-blue_box type_normal"><div class="box_title"><span class="span__box_title">スコア結果</span></div><div class="cboxcomment">
・モバイル：22<br />
・デスクトップ：63<br />
</div></div>
<p>スマフォ版は初めて20台へ！うーむ劇的には変わらないですね。ただ、<span class="fwb">PC版は安定してスコアが60代になってきました！</span></p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/10/th_11_sitespeed_how3_gtmetrix.jpg" alt="gtmetrix.com"></p>
<p>gtmetrixでも見て見ると、やや改善が見られました。</p>
<div class="supplement boader">
・PageSpeed Score (59%) E<br />
・Fully Loaded Time9.0s<br />
</div>
<p>ロード時間が9.8s → 9.0sとちょいと早くなっている感があります。</p>
<h3>4. PHPのバージョンを最新に</h3>
<p>WordPressサイトはPHPという言語で動作しており、<span class="fwb">PHPのバージョンを最新のものにしておくとサイトスピードが改善できたり、セキュリティ面でもより安全にサイト運営ができます</span>。最新バージョンであるPHP7は、PHP5に比べ2倍以上のパフォーマンス改善を見込めるようです。</p>
<p>ただし、場合によっては不具合が起きるケースもあるので慎重に作業を進めましょう。現状のバージョンがPHP 5.6.40でしたので、これをPHP 7.3へ変更します。</p>
<p>PHPのバージョンアップ方法の詳細はこちらの記事から ↓↓<br />
<div class="related_article typesimple"><a class="related_article__link no-icon" href="https://tekito-style.me/columns/plugin-php-compatibilitychecker"><figure class="eyecatch of-cover thum"><img loading="lazy" decoding="async" width="485" height="173" src="https://tekito-style.me/wp-content/uploads/2019/09/th_0top3_PHP-Compatibility-Checker-485x173.jpg" class="archives-eyecatch-image attachment-oc-post-thum wp-post-image" alt="" srcset="https://tekito-style.me/wp-content/uploads/2019/09/th_0top3_PHP-Compatibility-Checker-485x173.jpg 485w, https://tekito-style.me/wp-content/uploads/2019/09/th_0top3_PHP-Compatibility-Checker-300x107.jpg 300w, https://tekito-style.me/wp-content/uploads/2019/09/th_0top3_PHP-Compatibility-Checker-768x274.jpg 768w, https://tekito-style.me/wp-content/uploads/2019/09/th_0top3_PHP-Compatibility-Checker-1024x365.jpg 1024w, https://tekito-style.me/wp-content/uploads/2019/09/th_0top3_PHP-Compatibility-Checker.jpg 1200w" sizes="(max-width: 485px) 45vw, 485px" /></figure><div class="related_article__meta archives_post__meta inbox"><div class="related_article__ttl ttl"><span class="labeltext">関連記事</span>PHP Compatibility Checkerの使い方・設定方法まとめ！PHPバージョンUPで必須のプラグイン</div><time class="time__date gf undo">2020.04.20</time></div></a></div>
<p>各主要サーバーごとのバージョン確認方法は、下記公式サイトをご確認ください。</p>
<div class="supplement boader">
<ul>
<li><a href="https://help.sakura.ad.jp/hc/ja/articles/115000135681-PHP%E3%81%AE%E3%83%90%E3%83%BC%E3%82%B8%E3%83%A7%E3%83%B3%E5%A4%89%E6%9B%B4" target="_blank" rel="noopener noreferrer">さくらサーバーのPHPバージョン確認方法</a></li>
<li><a href="https://www.xserver.ne.jp/manual/man_program_php_ver.php" target="_blank" rel="noopener noreferrer">エックスサーバーのPHPバージョン確認方法</a></li>
<li><a href="https://lolipop.jp/manual/user/php-setting/" target="_blank" rel="noopener noreferrer">ロリポップのPHPバージョン確認方法</a></li>
<li><a href="https://help.mixhost.jp/hc/ja/articles/115003736351-PHP%E3%81%AE%E3%83%90%E3%83%BC%E3%82%B8%E3%83%A7%E3%83%B3%E3%82%92%E7%A2%BA%E8%AA%8D%E3%81%99%E3%82%8B%E6%96%B9%E6%B3%95" target="_blank" rel="noopener noreferrer">mixhostのPHPバージョン確認方法</a></li>
</ul>
</div>
<h4>サイトスピード スコア結果</h4>
<div class="cbox intitle is-style-blue_box type_normal"><div class="box_title"><span class="span__box_title">スコア結果</span></div><div class="cboxcomment">
・モバイル：20<br />
・デスクトップ：53<br />
</div></div>
<p>うーむ、思った以上の効果は見込めなかったですね。むしろ数値が下がっている……。そもそもサーバーが最新のモジュール版ではなく、従来のCGI版なのもありますが、いったんこのまま進めていきましょう。</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/10/th_12_sitespeed_how4_gtmetrix.jpg" alt="gtmetrix.com"></p>
<p>ただgtmetrix上では、ロードタイムが8.7sと、ようやく9秒を切りましたね。</p>
<div class="supplement boader">
PageSpeed Score（56%）E<br />
Fully Loaded Time　8.7s<br />
</div>
<p>ちなみにPHPのバージョンもそうですが、WordPressも常に最新のバージョンに変更しておきましょう！</p>
<h3>5. 最新の画像フォーマット「WebP」に対応する</h3>
<p>WebP（ウェッピー）とは、Googleが開発した最新の静止画像フォーマット。<span class="fwb">WebPは従来の画像フォーマットより圧縮率が高く、導入すれば20〜30%近く軽量化することが可能</span>です。</p>
<blockquote><p>
<span class="fwb">A new image format for the Web</span><br />
WebP lossless images are 26% smaller in size compared to PNGs. WebP lossy images are 25-34% smaller than comparable JPEG images at equivalent SSIM quality index.</p>
<p>（<span class="fwb">Web用の新しい画像形式</span><br />
WebPでロスレス圧縮（可逆圧縮）された画像は、PNGと比較してファイルサイズが26％小さくなります。またWebPで非可逆圧縮された画像は、JPEGの場合、同等のSSIM品質指標の画像よりも25〜34％サイズが小さくなります。）<br />
<quote class="fs13 fcNote">by：<a href="https://developers.google.com/speed/webp" target="_blank" rel="noopener noreferrer">https://developers.google.com/speed/webp</a></quote></p></blockquote>
<p>ただしChrome、Edge、Firefox、Operaは対応していますが、AppleのSafariは未対応となっています。ですのでSafariとそれ以外のブラウザで画像フォーマットを切り替える処理をする必要があります。</p>
<p>先ほど紹介した画像圧縮・最適化のプラグイン「<a href="https://tekito-style.me/columns/wordpress-plugin-eww-imageoptimizer">EWWW Image Optimizer</a>を使えば、比較的簡単に対応可能です。</p>
<p>Webp対応の詳細はこちらの記事から ↓↓<br />
<div class="related_article typesimple"><a class="related_article__link no-icon" href="https://tekito-style.me/columns/wordpress-image-webp"><figure class="eyecatch of-cover thum"><img loading="lazy" decoding="async" width="485" height="283" src="https://tekito-style.me/wp-content/uploads/2019/09/th_th_webp-too-485x283.jpg" class="archives-eyecatch-image attachment-oc-post-thum wp-post-image" alt="" srcset="https://tekito-style.me/wp-content/uploads/2019/09/th_th_webp-too-485x283.jpg 485w, https://tekito-style.me/wp-content/uploads/2019/09/th_th_webp-too-300x175.jpg 300w, https://tekito-style.me/wp-content/uploads/2019/09/th_th_webp-too-768x448.jpg 768w, https://tekito-style.me/wp-content/uploads/2019/09/th_th_webp-too-1024x597.jpg 1024w, https://tekito-style.me/wp-content/uploads/2019/09/th_th_webp-too.jpg 1200w" sizes="(max-width: 485px) 45vw, 485px" /></figure><div class="related_article__meta archives_post__meta inbox"><div class="related_article__ttl ttl"><span class="labeltext">関連記事</span>WordPressサイトで画像をWebP（ウェッピー）対応し軽量化する方法</div><time class="time__date gf undo">2020.04.20</time></div></a></div>
<h4>サイトスピード スコア結果</h4>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/11/th_13_sitespeed_how4.jpg" alt="PageSpeed Insights"></p>
<div class="cbox intitle is-style-blue_box type_normal"><div class="box_title"><span class="span__box_title">スコア結果</span></div><div class="cboxcomment">
・モバイル：25<br />
・デスクトップ：75<br />
</div></div>
<p>合格項目が12と、着実に増えてますね！</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/11/th_14_sitespeed_how5_PC.jpg" alt="PageSpeed Insights"></p>
<p>モバイルのスコアは微増し、<span class="fwb">PC版スコアもついに70台に！</span></p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/11/th_15_sitespeed_how5_SP.jpg" alt="PageSpeed Insights"></p>
<p>それにしても、モバイルはまだまだですね……。</p>
<div class="supplement boader">
・PageSpeed Score（59%）E<br />
・Fully Loaded Time：4.1s<br />
</div>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/11/th_16_sitespeed_how5_gtmetrix.jpg" alt="gtmetrix.com"></p>
<p>gtmetrix.comでは、<span class="fwb">フルロード時間が4秒台に！！</span>最初は9.8sだったので、ここまでで6秒早くなりました！！</p>
<h3>6. 画像の遅延読み込み</h3>
<p>画像データは重いため、全てを一気に読む込むと表示スピードに影響します。そこで<span class="fwb">画像を遅延読み込み（Lazy Load）させることで、画像を読み込むタイミングを調整しサイトの表示速度を改善できます</span>。</p>
<p>「BJ Lazy Load」というプラグインを活用することで、簡単に導入できます。ただし遅延読み込みされる画像データが、適切にGoogleのbotにクロールされるように微調整が必要です。</p>
<p>プラグインの設定方法については下記記事をご確認くださいませ。<br />
<div class="related_article typesimple"><a class="related_article__link no-icon" href="https://tekito-style.me/columns/wordpress-plugin-bj-lazyload"><figure class="eyecatch of-cover thum"><img loading="lazy" decoding="async" width="485" height="283" src="https://tekito-style.me/wp-content/uploads/2019/10/th_lazyload_top_1014-2-485x283.jpg" class="archives-eyecatch-image attachment-oc-post-thum wp-post-image" alt="" srcset="https://tekito-style.me/wp-content/uploads/2019/10/th_lazyload_top_1014-2-485x283.jpg 485w, https://tekito-style.me/wp-content/uploads/2019/10/th_lazyload_top_1014-2-300x175.jpg 300w, https://tekito-style.me/wp-content/uploads/2019/10/th_lazyload_top_1014-2-768x448.jpg 768w, https://tekito-style.me/wp-content/uploads/2019/10/th_lazyload_top_1014-2-1024x597.jpg 1024w, https://tekito-style.me/wp-content/uploads/2019/10/th_lazyload_top_1014-2.jpg 1200w" sizes="(max-width: 485px) 45vw, 485px" /></figure><div class="related_article__meta archives_post__meta inbox"><div class="related_article__ttl ttl"><span class="labeltext">関連記事</span>画像の遅延読み込みをするWPプラグインBJ Lazy Loadの使い方・設定方法まとめ</div><time class="time__date gf undo">2020.04.20</time></div></a></div>
<div class="cbox intitle is-style-red_box type_normal"><div class="box_title"><span class="span__box_title">ネイティブLazy-loadについて</span></div><div class="cboxcomment">
※先日ネイティブLazy-loadをWordPressで簡単実装するプラグインをGoogleが公開しました。Google提供のプラグインなので、これから導入を検討される方はこちらを実装した方が良さそうです。<br />
<a href="https://ja.wordpress.org/plugins/native-lazyload/" target="_blank" rel="noopener noreferrer"><br />
Native Lazyload</a><br />
</div></div>
<h4>サイトスピード スコア結果</h4>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/11/th_17_sitespeed_how6_SP.jpg" alt="PageSpeed Insights"></p>
<div class="cbox intitle is-style-blue_box type_normal"><div class="box_title"><span class="span__box_title">スコア結果</span></div><div class="cboxcomment">
・モバイル：32<br />
・デスクトップ：64<br />
</div></div>
<p>PCはちょい下がってますが、<span class="fwb">モバイル版のスコアが上がってますね〜！</span>まだまだではありますが……。</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/11/th_18_sitespeed_how6_gtmetrix.jpg" alt="gtmetrix.com"></p>
<div class="supplement boader">
PageSpeed Score（85%）B<br />
Fully Loaded Time：7.1s<br />
</div>
gtmetrixではページスコアがこれまでずっとEでしたが、初めてBにまで上がりました！</p>
<h3>7. JavaScriptをフッターで読み込む</h3>
<p>サイトスピード対策として、JavascriptやCSSなどのリソースの読み込みを遅らせる方法があります。サイトのヘッダーに挿入しているリソースを、フッターで読み込ませることでレンダリング速度を改善できる可能性があります。</p>
<p>PageSpeed Insightsで下記のよう指摘される項目ですね。</p>
<blockquote>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/11/th_21_sitespeed_how8.jpg" alt="PageSpeed Insights"></p>
<p>「レンダリングを妨げるリソースの除外」<br />
「ページの初回ペイントをリソースが阻害しています。クリティカルな JS や CSS はインラインで配信し、それ以外の JS やスタイルはすべて遅らせることをご検討ください。」</p>
<p><span class="fs13 fcNote">by：<a href="https://developers.google.com/speed/pagespeed/insights/" target="_blank" rel="noopener noreferrer">PageSpeed Insights</a></span></p></blockquote>
<p>プラグインを使わずソースコードを自分で調整するのが良いのですが、自分でいじれない場合は「Scripts-To-Footer」というプラグインがおすすめです。</p>
<p>レンダリングブロックを排除してくれますが、JSの読み込みを遅らすことで動作エラーや計測エラーが起こる場合があります。jQueryなどが多用されていたり、計測ツールを色々導入している場合には注意してみてください。</p>
<p>プラグインの詳細はこちらから↓<br />
<div class="related_article typesimple"><a class="related_article__link no-icon" href="https://tekito-style.me/columns/wordpress-plugin-scriptstofooter"><figure class="eyecatch of-cover thum"><img loading="lazy" decoding="async" width="485" height="229" src="https://tekito-style.me/wp-content/uploads/2019/09/th_0_top-485x229.jpg" class="archives-eyecatch-image attachment-oc-post-thum wp-post-image" alt="" srcset="https://tekito-style.me/wp-content/uploads/2019/09/th_0_top-485x229.jpg 485w, https://tekito-style.me/wp-content/uploads/2019/09/th_0_top-300x141.jpg 300w, https://tekito-style.me/wp-content/uploads/2019/09/th_0_top-768x362.jpg 768w, https://tekito-style.me/wp-content/uploads/2019/09/th_0_top-1024x483.jpg 1024w, https://tekito-style.me/wp-content/uploads/2019/09/th_0_top.jpg 1044w" sizes="(max-width: 485px) 45vw, 485px" /></figure><div class="related_article__meta archives_post__meta inbox"><div class="related_article__ttl ttl"><span class="labeltext">関連記事</span>Scripts-To-Footerの使い方・設定方法まとめ！JSをフッターに一括移動できるプラグイン</div><time class="time__date gf undo">2020.04.20</time></div></a></div>
<h4>サイトスピード スコア結果</h4>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/11/th_22_sitespeed_how8.jpg" alt="PageSpeed Insights"></p>
<div class="cbox intitle is-style-blue_box type_normal"><div class="box_title"><span class="span__box_title">スコア結果</span></div><div class="cboxcomment">
・モバイル：26<br />
・デスクトップ：70<br />
</div></div>
<p>結果はあまり前後で変わらず……。しかしレンダリングを妨げるリソースの除外が、1.47s → 1.25 sに変わっているので、やや減ってますね。計測ツールも整理と削除を今後検討してみます。</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/11/th_23_sitespeed_how8.jpg" alt="gtmetrix.com"></p>
<div class="supplement boader">
PageSpeed Score（74%）C<br />
Fully Loaded Time：8.6s<br />
</div>
<p>gtmetrixでもそこまで変化はありませんでした。</p>
<h3>8. CSSやJSなどの軽量化</h3>
<p>画像ファイルの最適化の他にも、HTMLやCSS、Javascriptなどのリソースを最適化することで、スピード改善で一定の効果が見込めます。「<a href="https://tekito-style.me/columns/wordpress-plugin-autoptimize">Autoptimize</a>」というプラグインを使えば、主要なリソースを簡単に軽量化・圧縮してくれるのでとても便利です。</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/11/th_24_sitespeed_how9.jpg" alt="Autoptimize"></p>
<p>こんな感じで、ぽちぽち設定項目にチェックを入れるだけでOKです。プラグイン使い方は下記記事をご参考ください。<br />
<div class="related_article typesimple"><a class="related_article__link no-icon" href="https://tekito-style.me/columns/wordpress-plugin-autoptimize"><figure class="eyecatch of-cover thum"><img loading="lazy" decoding="async" width="485" height="283" src="https://tekito-style.me/wp-content/uploads/2019/10/Autoptimize_top_1006-485x283.png" class="archives-eyecatch-image attachment-oc-post-thum wp-post-image" alt="" srcset="https://tekito-style.me/wp-content/uploads/2019/10/Autoptimize_top_1006-485x283.png 485w, https://tekito-style.me/wp-content/uploads/2019/10/Autoptimize_top_1006-1536x896.png 1536w, https://tekito-style.me/wp-content/uploads/2019/10/Autoptimize_top_1006-2048x1195.png 2048w, https://tekito-style.me/wp-content/uploads/2019/10/Autoptimize_top_1006-300x175.png 300w, https://tekito-style.me/wp-content/uploads/2019/10/Autoptimize_top_1006-768x448.png 768w, https://tekito-style.me/wp-content/uploads/2019/10/Autoptimize_top_1006-1024x597.png 1024w" sizes="(max-width: 485px) 45vw, 485px" /></figure><div class="related_article__meta archives_post__meta inbox"><div class="related_article__ttl ttl"><span class="labeltext">関連記事</span>Autoptimizeの使い方・設定方法を解説【CSSやJSを最適化するWPプラグイン】</div><time class="time__date gf undo">2020.04.20</time></div></a></div>
<h4>サイトスピード スコア結果</h4>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/11/th_25_sitespeed_how9.jpg" alt="PageSpeed Insights"></p>
<div class="cbox intitle is-style-blue_box type_normal"><div class="box_title"><span class="span__box_title">スコア結果</span></div><div class="cboxcomment">
・モバイル：49<br />
・デスクトップ：80<br />
</div></div>
<p><span class="fwb">モバイル版の数値がこれまで見たことない数字に……！</span>なかなか上がらなかった数値なので、まだ50も超えてませんが嬉しい限り。</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/11/th_28_sitespeed_how9.jpg" alt="PageSpeed Insights"></p>
<p><span class="fwb">PC版もスコアがついに80台へ！</span></p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/11/th_26_sitespeed_how9.jpg" alt="PageSpeed Insights"></p>
<p>モバイル版は「レンダリングを妨げるリソースの除外」が、1.25ss → 0.64ssまで下がっています。</p>
<p>あとは「サーバー応答時間の短縮（TTFB）」を改善していけばいいのですかね。あとモジュール内の画像が悪さをしているようので、ここも調整の必要そうです。</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/11/th_29_sitespeed_how9.jpg" alt="gtmetrix.com"></p>
<div class="supplement boader">
PageSpeed Score (72%）C<br />
Fully Loaded Time：8.0s<br />
</div>
<p>ちなみにgtmetrixでは大きな変化がありませんでしたね。</p>
<h3>9. ブラウザのキャッシュを活用する</h3>
<p>ブラウザのキャッシュを活用すると、HTMLやCSS、画像などのリソースをブラウザが一時保存（ブラウザキャッシュ）してくれます。そうすることで、<span class="fwb">ユーザーが同じページを再訪問した時に表示スピードを上げることができます</span>。</p>
<p>ブラウザキャッシュを有効化するためには、プラグインは不要です。サーバー内にある「.htaccess」というファイルに特定のコードを追記します。FTPソフトを使う必要があるのですが、そこまで難しくはないです。</p>
<p>詳細な設定方法はこちらからご確認ください。 ↓↓<br />
<div class="related_article typesimple"><a class="related_article__link no-icon" href="https://tekito-style.me/columns/sitespeed-browser-cashe"><figure class="eyecatch of-cover thum"><img loading="lazy" decoding="async" width="485" height="378" src="https://tekito-style.me/wp-content/uploads/2019/09/top_browser-cashe-485x378.png" class="archives-eyecatch-image attachment-oc-post-thum wp-post-image" alt="" srcset="https://tekito-style.me/wp-content/uploads/2019/09/top_browser-cashe-485x378.png 485w, https://tekito-style.me/wp-content/uploads/2019/09/top_browser-cashe-300x234.png 300w, https://tekito-style.me/wp-content/uploads/2019/09/top_browser-cashe-768x598.png 768w, https://tekito-style.me/wp-content/uploads/2019/09/top_browser-cashe.png 992w" sizes="(max-width: 485px) 45vw, 485px" /></figure><div class="related_article__meta archives_post__meta inbox"><div class="related_article__ttl ttl"><span class="labeltext">関連記事</span>プラグイン不要！ブラウザキャッシュを設定しWordPressのサイトスピードを改善する方法</div><time class="time__date gf undo">2019.11.30</time></div></a></div>
<h4>サイトスピード スコア結果</h4>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/11/th_30_sitespeed_how10.jpg" alt="PageSpeed Insights"></p>
<div class="cbox intitle is-style-blue_box type_normal"><div class="box_title"><span class="span__box_title">スコア結果</span></div><div class="cboxcomment">
・モバイル：50<br />
・デスクトップ：75<br />
</div></div>
<p><span class="fwb">モバイル版のスコアがようやく50台に！</span></p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/11/th_31_sitespeed_how10.jpg" alt="PageSpeed Insights"></p>
<p>合格項目も14まで増えていますね。デスクトップ版もスコアが70〜80で安定してきましたね（合格項目11）。</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/11/th_32_sitespeed_how10.jpg" alt="gtmetrix.com"></p>
<div class="supplement boader">
PageSpeed Score（75%）C<br />
YSlow Score（82%）B<br />
Fully Loaded Time：3.9s<br />
</div>
<p>gtmetrixで確認してみるとスピードスコアは変わっていませんが、フルロード時間が3秒台になっていました！またYSlow Scoreも初めてBに。</p>
<h3>10. サーバーのキャッシュ改善</h3>
<p>ブラウザではなく、サーバー上のキャッシュを改善することでも、サイトスピードを改善することが可能です。ややこしいのですが、<span class="fwb">サーバー上で事前にページを生成しキャッシュとして保存</span>しておくことで、表示速度を改善します。</p>
<p>「WP Fastest Cache」というプラグインが、設定も簡単で動作も比較的安定しているのでおすすめです。</p>
<p>またサーバーキャッシュ周りのプラグインはトラブルが発生する可能性が高いので、事前にバックアップを必ず取るようにしましょう……！</p>
<p>実際に僕もモバイルサイトなのに、PCのコンテンツが表示されるなど不具合がありました。お使いのWordPressテーマによっては、事前にバグやエラーの発生事例がないか、導入前にリサーチをしてみてください。</p>
<p>プラグインの設定方法は以下から ↓↓<br />
<div class="related_article typesimple"><a class="related_article__link no-icon" href="https://tekito-style.me/columns/wordpress-plugin-fastest-cache"><figure class="eyecatch of-cover thum"><img loading="lazy" decoding="async" width="485" height="283" src="https://tekito-style.me/wp-content/uploads/2019/10/th_WPFastestCache_top_1021-485x283.jpg" class="archives-eyecatch-image attachment-oc-post-thum wp-post-image" alt="" srcset="https://tekito-style.me/wp-content/uploads/2019/10/th_WPFastestCache_top_1021-485x283.jpg 485w, https://tekito-style.me/wp-content/uploads/2019/10/th_WPFastestCache_top_1021-300x175.jpg 300w, https://tekito-style.me/wp-content/uploads/2019/10/th_WPFastestCache_top_1021-768x448.jpg 768w, https://tekito-style.me/wp-content/uploads/2019/10/th_WPFastestCache_top_1021-1024x597.jpg 1024w, https://tekito-style.me/wp-content/uploads/2019/10/th_WPFastestCache_top_1021.jpg 1200w" sizes="(max-width: 485px) 45vw, 485px" /></figure><div class="related_article__meta archives_post__meta inbox"><div class="related_article__ttl ttl"><span class="labeltext">関連記事</span>WP Fastest Cacheの使い方・設定方法【キャッシュ改善のおすすめプラグイン】</div><time class="time__date gf undo">2020.04.20</time></div></a></div>
<h4>サイトスピード スコア結果</h4>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/11/th_33_sitespeed_how11.jpg" alt="PageSpeed Insights_PC"></p>
<div class="cbox intitle is-style-blue_box type_normal"><div class="box_title"><span class="span__box_title">スコア結果</span></div><div class="cboxcomment">
・モバイル：55合格した監査 (13)<br />
・デスクトップ：92 合格した監査 (13)！！<br />
</div></div>
<p><span class="fwb">デスクトップサイトは、念願の90台スコアをついに拝めることに……！</span>導入後、PC・SPともに「サーバーの応答時間が遅い（TTFB）」という指摘は解消されたましたね。PCに関してはもう広告の画像が重いくらいしか指摘されない感じです。ほとんどマックス値まで持ってこれました。</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/11/th_34_sitespeed_how11.jpg" alt="PageSpeed Insights_PC"></p>
<p>モバイル版も改善はしていますが、PCと比較し思ったよりは伸びず……。8割くらいいきたいところですが、なかなか難しいですね……。</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/11/th_35_sitespeed_how11.jpg" alt="gtmetrix.com"></p>
<div class="supplement boader">
PageSpeed Score（75%)）C<br />
YSlow Score（82%）B<br />
Fully Loaded Time：3.1s<br />
</div>
<p>gtmetrix.comでは、フルロード時間が、3秒前半台に！かなり早くなりましたね。</p>
<h3>11. 余計なウィジットや広告を取り除く</h3>
<p>ここからは微調整の施策になります。サイト上で不要なもの、機能していないものは思い切って外すことでスピード改善に繋がる可能性もあります。ですので不要なものは削除してみました。</p>
<div class="supplement boader">
<ul>
<li>アドセンスなどでクリック率の低い広告</li>
<li>利用されていないウィジェット</li>
<li>Youtube動画の埋め込み</li>
<li>Google Mapの埋め込み</li>
<li>テーマの不要なアニメーション</li>
</ul>
</div>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/11/th_18_sitespeed_how7.jpg" alt="PageSpeed Insights"></p>
<p>PageSpeed Insightsの注意事項を見ると、アドセンスなどで配信されている広告画像がWebpに対応していないので、それが遅くなっている要因のようです。これはコントロールできないので仕方ないですが、効果の薄いアドセンス広告などがある方は削除した方が良さげ。</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/11/th_19_sitespeed_how7.jpg" alt="Google Adsense"></p>
<p>インプレッションが少ない上に、収益も少ない広告は今回改めて整理し、サイトから削除してアーカイブしました。</p>
<p>僕は使っていませんがその他注意すべきものとしては、</p>
<p>・Facebook いいねBox<br />
・Twitterのタイムライン</p>
<p>などもプラグインで表示しているサイトもありますが、読み込み動作が重くなる要因なので、テストでいったん外してみることをおすすめします。</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/11/th_20_sitespeed_how7.jpg" alt="Stork"></p>
<p>また僕が使っているテーマ「Stork」のスライダー付き記事一覧（pickup記事）機能や、テキストのフェードインなどアニメーション機能についても今回検討してみました。スライダーはTOPページだけなので悩みましたが、スライドさせていた余分な記事の数を11記事から6個記事へ整理。フェードインアニメーションはオフにしています。</p>
<h4>サイトスピード スコア結果</h4>
<p>結果、サイトスピードスコアへの影響はほとんど変わらず…… といった結果でした。特に重いウィジットや埋め込みなどは使っていなかったので、もし使っている方は試してみてください！</p>
<h3>12. 個別の画像調整</h3>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/11/th_27_sitespeed_how9.jpg" alt="PageSpeed Insights"></p>
<p>こちらも微調整。「適切なサイズの画像」の指摘を確認してみると、テーマのモジュール内の画像と、サイトロゴ画像、プロフィール画像など、特定の画像が最適化されておらず、スピードへ悪影響しているようでした。</p>
<p>画像最適化プラグインの対象から抜け漏れていたようなので、Th_markersとイメージオプティムを使い、1枚1枚リサイズと圧縮を行い再アップロード。</p>
<div class="supplement boader">
・モジュール内の画像<br />
328px → 150pxへ<br />
194 KB → 6KB</p>
<p>・プロフィール画像<br />
72kb　→ 9kb<br />
</div>
<p>こんな感じまで、画像サイズを落とせました。</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/11/th_36_sitespeed_how12.jpg" alt="search regex"></p>
<p>同一の画像はすべて差し替えます。差し替えには一括置換ツールの「search regex」を利用しました。</p>
<h4>サイトスピード スコア結果</h4>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/11/th_37_sitespeed_how12.jpg" alt="PageSpeed Insights"></p>
<p>モバイル版については「画像の最適サイズ」については言及されなくなり、合格項目が14に。ただスピードはそこまで変わらず、といった結果となりました。</p>
<h2>今回実施しなかったけど、今度検討する施策</h2>
<p>今回のスピード改善施策としては実施しませんでしたが、今後検討し随時実施してみようと思っている施策をメモしておきます。検証でき次第、結果をレポートできればと思います！</p>
<h3>CDNの利用</h3>
<p>Cloud Flareなど、CDNの利用もサイトスピードの改善に繋がりそうです。CDNは簡単に言うと、Webサイトを複数の地域の複数のサーバーで共有するサービス。今回導入しようかと検討しましたが、色々と設定・リサーチなどが必要そうだったのでいったん保留にします。</p>
<p>途中で力尽きたので、また時間ある時にテストしてみます！</p>
<h3>サーバーの性能改善・移転</h3>
<p>僕が使っているのではさくらのレンタルサーバーなのですが、サーバーの応答時間を削減するために高速サーバーへ変える、高いプランへ切り替えることを検討しました。</p>
<p>さくらサーバーの場合、2018年4月以降に登録したユーザーは処理の早いモジュール版をデフォルトで使えるのですが、それ以前に登録したユーザーは従来のCGI版しか使えないんですよね（プレミアム、ビジネスプランは切り替え可能）。</p>
<p>※参考：<a href="https://knowledge.sakura.ad.jp/20999/
" target="_blank" rel="noopener noreferrer">さくらのレンタルサーバでWordPressサイトを高速に動かす方法。モジュール版PHPって何!?</a></p>
<p>ですので、さくらサーバーを同じプランか別のプランで再度契約し直すか、別のサーバーに切り替えるかしないといけません。</p>
<p>この際せっかくなので、別サーバーも使ってみようかなーとは思っています。GMOが提供している高性能レンタルサーバ「<a href="https://px.a8.net/svt/ejp?a8mat=35F9PO+F5YIIA+50+5SIFHE" rel="nofollow">ConoHa WING(コノハウィング)</a><img loading="lazy" decoding="async" border="0" width="1" height="1" src="https://www13.a8.net/0.gif?a8mat=35F9PO+F5YIIA+50+5SIFHE" alt="">」や、安定感のある「<a href="https://px.a8.net/svt/ejp?a8mat=35SL3K+2S0UEQ+CO4+609HU" rel="nofollow">エックスサーバー</a><img loading="lazy" decoding="async" border="0" width="1" height="1" src="https://www12.a8.net/0.gif?a8mat=35SL3K+2S0UEQ+CO4+609HU" alt="">」など。</p>
<p>サーバー移転となるので、ある程度準備した上で随時実施してみようかなと思います。ConoHaは最近よく名前を聞くので、ちょっと使ってみたいですね。</p>
<p><a href="https://px.a8.net/svt/ejp?a8mat=35F9PO+F5YIIA+50+5SI01U" rel="nofollow">国内最速・高安定の高性能レンタルサーバー【ConoHa WING】</a><img loading="lazy" decoding="async" border="0" width="1" height="1" src="https://www16.a8.net/0.gif?a8mat=35F9PO+F5YIIA+50+5SI01U" alt=""><br />
<a href="https://px.a8.net/svt/ejp?a8mat=35SL3K+2S0UEQ+CO4+60OXE" rel="nofollow">月額900円(税抜)から、高速・多機能・高安定レンタルサーバー『エックスサーバー』</a><br />
<img loading="lazy" decoding="async" border="0" width="1" height="1" src="https://www19.a8.net/0.gif?a8mat=35SL3K+2S0UEQ+CO4+60OXE" alt=""></p>
<h3>AMP対応する</h3>
<p>モバイル版のサイト改善施策として、AMP（Accelerated Mobile Pages）対応することも検討しています。Googleが推奨しているサイトコンテンツを高速で表示できる仕様なので、可能な限り導入すべきではあります。ただし色々と制約があったり調整が必要なので、導入するかどうかは検討中です。</p>
<p>現職で扱っているサービスがAMP対応をしていて、その開発ディレクションなどをしていたのですが、JSが自由に使えなかったり、ファイルサイズなどに制限があって表示したいコンテンツを表示できない、レイアウトが崩れたりなど、色々と悩ましい感じですね……。</p>
<p>AMP用のWordPressプラグインもあるので、テストで使ってみようかな。</p>
<p>「Google developers ブログ」にAMPに関してこんな記事もありました。AMP導入を検討している方は参考にしてみては？<br />
<a href="https://developers-jp.googleblog.com/2019/07/amp.html" target="_blank" rel="noopener noreferrer">AMP の誤解を払拭する</a></p>
<h3>プラグインの再調整</h3>
<p>今回サイトスピード改善で色々なプラグインを入れましたが、できる限りプラグインは入れないほうが処理に負荷がかかりません。その他のプラグインも含めて、自力で設定しプラグインを使わない方法はないか、自分でもできそうか含め改めて検討してみようかなと思います。</p>
<h3>速度の早いテーマへ変更</h3>
<p>本サイトはStorkを使っていますが、高速なテーマに変更するのも手段としてありかなと検討しています。色々とカスタマイズをしたので、テーマ切替時に色々と設定をし直す必要があり正直面倒くさいのですが……。</p>
<p>参考までに下記のテーマ「Godios」はクソ早いです（笑）。ページ遷移速度0秒というコピーがすごい。有料（4980円）ですが、使ってみる価値はありそう。<br />
<a href="https://godios.simmon.design" trget="_blank">「Godios」デモサイト</a></p>
<p>最近Storkの新テーマ「<a href="https://px.a8.net/svt/ejp?a8mat=35FNTT+5YCTU+3PSE+63WO2" rel="nofollow">STORK19</a><img loading="lazy" decoding="async" border="0" width="1" height="1" src="https://www19.a8.net/0.gif?a8mat=35FNTT+5YCTU+3PSE+63WO2" alt="">」が出たようなので、そちらも使ってみようか検討中です。Storkのデザインの良さはそのままに、機能追加と従来のもっさり感がなくなり、かなり高速になっていると評判ですね。</p>
<p>めっちゃ使ってみたいのですが、またカスタマイズし直さないといけないのか……と思うと腰が重くなります（笑）。1日じっくり時間取れたらやってみよう……。<br />
<a href="https://px.a8.net/svt/ejp?a8mat=35FNTT+5YCTU+3PSE+63WO2" rel="nofollow">WordPressテーマ「STORK19」</a><br />
<img loading="lazy" decoding="async" border="0" width="1" height="1" src="https://www19.a8.net/0.gif?a8mat=35FNTT+5YCTU+3PSE+63WO2" alt=""></p>
<h2>まとめ</h2>
<p>ここまでWordPressのスピード改善について施策と結果をまとめてきましたが、いかがでしたでしょうか？スピード改善周りについて予備知識があまりなかったので、リサーチと施策の洗い出し、施策の実施と計測と結果のまとめなど、諸々1週間近くかかってしまいました。けっこう疲れた（笑）。</p>
<p>基本的に初心者の方でも取り組める施策ばかりです。動作環境によってテスト結果も異なるかと思うので、ぜひ参考にテストしてみてくださいませ。</p>
<p>今回の結果をまとめると、検証前後で下記のように改善できました。</p>
<div class="cbox intitle is-style-blue_box type_normal"><div class="box_title"><span class="span__box_title">検証前後のサイトスピード</span></div><div class="cboxcomment">
<span class="fwb">デスクトップ：44 → 92</span><br />
<span class="fwb">モバイル：13 → 55</span></p>
<p>※フルロード時間：9.8s → 3.1s<br />
</div></div>
<p>PC版はスコア90超えを達成！モバイル版はまだまだ改善の余地があるので、今後も追加で実施し、改善に繋がった施策は随時更新していきたいと思います。</p>
<p>最後までお読みいただき、誠にありがとうございました！</p>The post <a href="https://tekito-style.me/columns/wordpress-sitespeed">WordPressのサイトスピード改善で実施した12の施策とスコア結果まとめ</a> first appeared on <a href="https://tekito-style.me">Tekito style.me</a>.]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>WP Fastest Cacheの使い方・設定方法【キャッシュ改善のおすすめプラグイン】</title>
		<link>https://tekito-style.me/columns/wordpress-plugin-fastest-cache</link>
		
		<dc:creator><![CDATA[やすのり]]></dc:creator>
		<pubDate>Mon, 21 Oct 2019 15:16:48 +0000</pubDate>
				<category><![CDATA[Webマーケティング]]></category>
		<category><![CDATA[WordPress/ブログ運営]]></category>
		<category><![CDATA[WordPressプラグイン]]></category>
		<category><![CDATA[サイトスピード改善]]></category>
		<guid isPermaLink="false">https://tekito-style.me/?p=3902</guid>

					<description><![CDATA[<p>サイトスピード改善で一定の成果を見込める施策として、キャッシュ改善があります。サーバー上で事前にページを生成し、キャッシュとして保存しておくことで、表示速度を改善することができます。 WordPressサイトの場合は、プ...</p>
The post <a href="https://tekito-style.me/columns/wordpress-plugin-fastest-cache">WP Fastest Cacheの使い方・設定方法【キャッシュ改善のおすすめプラグイン】</a> first appeared on <a href="https://tekito-style.me">Tekito style.me</a>.]]></description>
										<content:encoded><![CDATA[<p><!--


<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/10/th_WPFastestCache_top_1021.jpg" alt="WP Fastest Cache"></p>



--><div class="voice cf l "><figure class="icon"><img loading="lazy" decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_th_IMG_0018_circle.jpg" class="voice_icon__img" width="150" height="150"><figcaption class="name">やすのり</figcaption></figure><div class="voicecomment">こんにちは！「Tekito style」を運営している<a href="https://twitter.com/98nasi_nori" target="_blank" rel="noopener noreferrer">やすのり（@98nasi_nori）</a>です。普段は都内でWebディレクター/マーケターなどをしています。</div></div>
<p>サイトスピード改善で一定の成果を見込める施策として、キャッシュ改善があります。サーバー上で事前にページを生成し、キャッシュとして保存しておくことで、表示速度を改善することができます。</p>
<p>WordPressサイトの場合は、プラグインで導入することができます。<span class="fwb">おすすめなプラグインが「WP Fastest Cache」</span>。設定方法がシンプルなので、初心者でも比較的簡単に使うことができます。</p>
<p>キャッシュ系のプラグインはW3 Total CacheやWP Super Cacheなど色々あるのですが、比較的バグ報告が少なく（現状僕が使っているテーマ「Stork」との相性も加味し）、また簡単に使えるということでWP Fastest Cacheを選定しました。</p>
<p>ということで今回はWP Fastest Cacheの使い方や注意点などを解説していくので、キャッシュ改善を検討している方はぜひチェックしてみてください。</p>
<h2>WP Fastest Cacheの導入方法</h2>
<p>まずはWP Fastest Cacheの導入方法を見ていきましょう！基本的に他のWordPressプラグインと同じです。</p>
<h3>まずバックアップを必ず取る</h3>
<p>キャッシュ系のプラグインは、導入するとデザインが崩れたりPCとSPの切り分けができなくなったりと、様々なトラブルが発生する可能性があります。</p>
<p>環境やテーマなどによって何が起こるか予測しづらいので、<span class="fwb">設定する前に必ずバックアップを取りましょう！</span></p>
<p>バックアップには「UpdraftPlus」というプラグインがおすすめです。無料で簡単にバックアップデータを作成することが可能です。<br />
<div class="related_article typesimple"><a class="related_article__link no-icon" href="https://tekito-style.me/columns/wordpress-plugin-updraftplus"><figure class="eyecatch of-cover thum"><img loading="lazy" decoding="async" width="485" height="303" src="https://tekito-style.me/wp-content/uploads/2019/09/th_1topUpdraftPlus2-485x303.jpg" class="archives-eyecatch-image attachment-oc-post-thum wp-post-image" alt="" srcset="https://tekito-style.me/wp-content/uploads/2019/09/th_1topUpdraftPlus2-485x303.jpg 485w, https://tekito-style.me/wp-content/uploads/2019/09/th_1topUpdraftPlus2-300x188.jpg 300w, https://tekito-style.me/wp-content/uploads/2019/09/th_1topUpdraftPlus2-768x480.jpg 768w, https://tekito-style.me/wp-content/uploads/2019/09/th_1topUpdraftPlus2-1024x640.jpg 1024w, https://tekito-style.me/wp-content/uploads/2019/09/th_1topUpdraftPlus2.jpg 1200w" sizes="(max-width: 485px) 45vw, 485px" /></figure><div class="related_article__meta archives_post__meta inbox"><div class="related_article__ttl ttl"><span class="labeltext">関連記事</span>バックアップ専用プラグインUpdraftPlusの使い方・設定方法まとめ</div><time class="time__date gf undo">2022.02.22</time></div></a></div>
<h3>インストールと有効化</h3>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/10/th_1_WP-Fastest-Cache.jpg" alt="WP Fastest Cache"></p>
<p>管理画面のメニュー「プラグイン」&gt;「新規追加」から、「WP Fastest Cache」で検索。「いますぐインストール」をクリックし、有効化します。</p>
<p>画像のチーターは、速くなるからってことでしょうか？（笑）</p>
<h3>インストールされてるか確認</h3>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/10/th_2_WP-Fastest-Cache.jpg" alt="WP Fastest Cache"></p>
<p>インストールを完了すると、管理画面のサイドバーに「WP Fastest Cache」が追加されていればOKです。クリックして詳細を確認しましょう。</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/10/th_3_WP-Fastest-Cache.jpg" alt="WP Fastest Cache"></p>
<p>基本的にデフォルトで全ての設定項目がアンチェック状態なので、<span class="fwb">インストールしても設定しないと起動はしません</span>。キャッシュ系のプラグインはトラブルが多いので安心ですね。</p>
<h2>WP Fastest Cacheの使い方</h2>
<p>WP Fastest Cacheは多機能ですが、必要な項目をチェックするだけなので簡単に設定できます。確認していきましょう。</p>
<h3>1. 日本語設定に変更</h3>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/10/th_4_WP-Fastest-Cache.jpg" alt="WP Fastest Cache"></p>
<p>WP Fastest Cacheデフォルトでは言語が英語になっていますが、日本語表示も可能です。初心者にはありがたいですね！</p>
<p>先に「日本語」へ変更し、「変更を保存」しておきましょう。</p>
<h3>2. 詳細設定</h3>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/10/th_5-2_WP-Fastest-Cache.jpg" alt="WP Fastest Cache"></p>
<p>必要な項目をチェックするだけでOKです。</p>
<h4>キャッシュ</h4>
<p>こちらは有効にしないとプラグインそのものが機能しません。必ずチェックをつけましょう。</p>
<h4>Preload（プレロード）</h4>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/10/th_6_WP-Fastest-Cache.jpg" alt="WP Fastest Cache"></p>
<p>指定した項目のキャッシュを、自動で事前に作成してくれる機能です。クリックすると、詳細設定ができます。</p>
<p>よくユーザーが使うであろう下記の項目は、チェックしておくことをおすすめします。<br />
<div class="supplement boader">
<ul>
<li>Homepage（TOPページ）</li>
<li>Posts（投稿ページ）</li>
<li>Categories（カテゴリーページ）</li>
<li>Pages（固定ページ）</li>
<li>Tags（タグページ）</li>
</ul>
</div>
<h4>ログインユーザー</h4>
<p>チェックすると、ログインユーザー（サイト管理者）に対してキャッシュを表示しなくなります。</p>
<p>サイト管理者の場合、キャッシュが残るとテーマなどをカスタマイズしたときに変更内容の確認がしにくくなります。ですのでチェックすることをおすすめします。</p>
<h4>モバイル</h4>
<p><span class="fwb">モバイルの項目はいったんチェックしておきましょう</span>。テーマによってはスマフォ版のデザインが崩れたり、PCとスマフォ版の切り替えができなくなったりと多々エラーが発生するようです。</p>
<p>テーマが僕と同じStorkの場合、不具合が発生する事例を確認しています。実際に僕もこの項目にチェックをつけないでスマフォ版を確認したら、PC版のサイドバーがSP版で表示されるエラーが発生していました。</p>
<p>ですので、この項目にチェックを入れ、モバイルユーザーにはキャッシュを表示しないようにしています。</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/10/th_8_WP-Fastest-Cache.jpg" alt="WP Fastest Cache"></p>
<p>Googleが提供するサイトスピード計測ツール「<a href="https://developers.google.com/speed/pagespeed/insights/" target="_blank" rel="noopener noreferrer">PageSpeed Insights</a>」で提案される改善項目で、スマフォ版の「サーバー応答時間の短縮（TTFB）」がもともと未解決でしたが、「モバイル」の項目を外すと合格できました。</p>
<p>しかしエラーが発生するのでこの項目にチェックをつけると、やはり「サーバー応答時間の短縮（TTFB）」の指摘が再度されるように……。スマフォのサイトスピードを改善したいので悩ましいですが、こればかりは仕方ないですね。</p>
<p>もしチェックを外し、モバイルユーザーに対してキャッシュを表示したい場合は、<span class="fwb">有効後に必ずPC版とスマフォ版それぞれにエラーやバグが発生していないか隈なく確認することとおすすめします</span>。</p>
<p>問題が起きたときは、「モバイル」をチェックして解除できますよ。</p>
<h4>新しい投稿</h4>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/10/th_7_WP-Fastest-Cache.jpg" alt="WP Fastest Cache"></p>
<p>「新しい投稿」はチェックしておきましょう（Clear All CasheでOK）。新規投稿する時に、指定した項目のキャッシュを削除することができます。</p>
<p>記事を投稿する度に古いキャッシュを削除し、新規キャッシュに入れ替えることで、定期的にキャッシュ状況を最新状態に保つことができます（記事更新頻度によりますが）。</p>
<h4>Update Post</h4>
<p>こちらは「新しい投稿」とは違い、記事を更新した場合にキャッシュを削除できる機能です。合わせてチェックしておきましょう。</p>
<h4>ファイル圧縮・最適化</h4>
<p>ファイル圧縮・最適化の項目は、他の専用プラグインで管理しているため今回チェックしませんでした。<br />
<div class="supplement boader">
<ul>
<li>HTMLの圧縮</li>
<li>CSSの圧縮</li>
<li>CSSの結合</li>
<li>JSの結合</li>
</ul>
</div>
他の圧縮系のプラグインを活用している場合、機能がバッティングするとエラーが発生したり、プラグインが正常に動作しない可能性があります。現状利用しているプラグインについて、事前に確認しておきましょう。</p>
<p>もしファイル圧縮が必要であればチェックしましょう。</p>
<p>参考までに、僕がファイル圧縮・最適化で使っているのは、「Autoptimize」というプラグインです。<br />
<div class="related_article typesimple"><a class="related_article__link no-icon" href="https://tekito-style.me/columns/wordpress-plugin-autoptimize"><figure class="eyecatch of-cover thum"><img loading="lazy" decoding="async" width="485" height="283" src="https://tekito-style.me/wp-content/uploads/2019/10/Autoptimize_top_1006-485x283.png" class="archives-eyecatch-image attachment-oc-post-thum wp-post-image" alt="" srcset="https://tekito-style.me/wp-content/uploads/2019/10/Autoptimize_top_1006-485x283.png 485w, https://tekito-style.me/wp-content/uploads/2019/10/Autoptimize_top_1006-1536x896.png 1536w, https://tekito-style.me/wp-content/uploads/2019/10/Autoptimize_top_1006-2048x1195.png 2048w, https://tekito-style.me/wp-content/uploads/2019/10/Autoptimize_top_1006-300x175.png 300w, https://tekito-style.me/wp-content/uploads/2019/10/Autoptimize_top_1006-768x448.png 768w, https://tekito-style.me/wp-content/uploads/2019/10/Autoptimize_top_1006-1024x597.png 1024w" sizes="(max-width: 485px) 45vw, 485px" /></figure><div class="related_article__meta archives_post__meta inbox"><div class="related_article__ttl ttl"><span class="labeltext">関連記事</span>Autoptimizeの使い方・設定方法を解説【CSSやJSを最適化するWPプラグイン】</div><time class="time__date gf undo">2020.04.20</time></div></a></div>
<h4>Gzip圧縮</h4>
<p>この項目も必要に応じてチェックしておきましょう。サイトリソースをサーバー上で圧縮することで、転送量を減らし高速化してくれます。</p>
<p>他のプラグインで設定している場合はチェックは不要です。</p>
<h4>ブラウザキャッシュ</h4>
<p>サーバー上ではなく、ブラウザ上でのキャッシュを生成してくれます。僕は.htaccessファイルに直接設定を記述しているので、今回はチェックを外します。</p>
<p>ブラウザキャッシュは、プラグインを利用しなくても比較的簡単に設定できます。キャッシュの設定も細かく指定できるので、以下記事もぜひ参考にしてみてくださいね。<br />
<div class="related_article typesimple"><a class="related_article__link no-icon" href="https://tekito-style.me/columns/sitespeed-browser-cashe"><figure class="eyecatch of-cover thum"><img loading="lazy" decoding="async" width="485" height="378" src="https://tekito-style.me/wp-content/uploads/2019/09/top_browser-cashe-485x378.png" class="archives-eyecatch-image attachment-oc-post-thum wp-post-image" alt="" srcset="https://tekito-style.me/wp-content/uploads/2019/09/top_browser-cashe-485x378.png 485w, https://tekito-style.me/wp-content/uploads/2019/09/top_browser-cashe-300x234.png 300w, https://tekito-style.me/wp-content/uploads/2019/09/top_browser-cashe-768x598.png 768w, https://tekito-style.me/wp-content/uploads/2019/09/top_browser-cashe.png 992w" sizes="(max-width: 485px) 45vw, 485px" /></figure><div class="related_article__meta archives_post__meta inbox"><div class="related_article__ttl ttl"><span class="labeltext">関連記事</span>プラグイン不要！ブラウザキャッシュを設定しWordPressのサイトスピードを改善する方法</div><time class="time__date gf undo">2019.11.30</time></div></a></div>
<p>ファイルを直接いじりたくない、現状他のプラグインでブラウザキャッシュを何も設定していない方は、こちらで簡易的に管理してもいいかなとは思います。</p>
<h3>3. キャッシュの削除方法</h3>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/10/th_9_WP-Fastest-Cache.jpg" alt="WP Fastest Cache"></p>
<p>上記の設定で、記事を投稿・更新した場合に定期的にキャッシュが削除・更新されるようになりましたが、「キャッシュの削除」タブから手動・もしくは自動更新で削除することもできます。</p>
<h4>キャッシュを削除</h4>
<p>キャッシュファルダ内の全てのキャシュを削除します。</p>
<h4>キャッシュと圧縮されたCSS/JSファイルを削除</h4>
<p>テーマのコードを変更するなどで、CSS/JSファイルを変更した場合はこちらをチェックしましょう。</p>
<h4>Timeout Rules</h4>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/10/th_9_WP-Fastest-Cache.jpg" alt="WP Fastest Cache"></p>
<p>「Add New Rule」をクリックすると、キャッシュを自動削除する頻度の調整が可能です。必要に応じて設定しておきましょう。</p>
<h2>WP Fastest Cacheを有効活用しよう！</h2>
<p>ここまでWP Fastest Cacheの使い方を紹介してきましたが、かなり簡単に設定できるのでぜひキャッシュ改善のプラグインとしておすすめしたいところです。</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/10/th_12_WP-Fastest-Cache.jpg" alt="WP Fastest Cache"></p>
<p>実際にPC版は「サーバーの応答時間が遅い（TTFB）」が解消され、サイトスピードスコアが70後半から90台へ上昇しました！</p>
<p>色々サイトスピード改善で試行錯誤していたのですが、キャッシュ周りで思った以上に改善できましたね。スマフォ版もスコア40前半から50台に改善したので、10前後のスコア改善に。スマフォはまだかなり改善の余地があるので、引き続き調整していきます……。</p>
<p>PCに関しては、広告で表示される画像が重いくらいしかもう指摘されない感じですね。</p>
<p>サイトスピードについては、キャッシュもそうですが画像周りの施策でもサイトスピードをかなり改善できたので、以下の記事もぜひチェックしてみてくださいね。<br />
<div class="related_article typesimple"><a class="related_article__link no-icon" href="https://tekito-style.me/columns/wordpress-plugin-eww-imageoptimizer"><figure class="eyecatch of-cover thum"><img loading="lazy" decoding="async" width="485" height="287" src="https://tekito-style.me/wp-content/uploads/2019/09/th_0_EWWWImageOptimizer-485x287.png" class="archives-eyecatch-image attachment-oc-post-thum wp-post-image" alt="" srcset="https://tekito-style.me/wp-content/uploads/2019/09/th_0_EWWWImageOptimizer-485x287.png 485w, https://tekito-style.me/wp-content/uploads/2019/09/th_0_EWWWImageOptimizer-300x178.png 300w, https://tekito-style.me/wp-content/uploads/2019/09/th_0_EWWWImageOptimizer-768x454.png 768w, https://tekito-style.me/wp-content/uploads/2019/09/th_0_EWWWImageOptimizer.png 1014w" sizes="(max-width: 485px) 45vw, 485px" /></figure><div class="related_article__meta archives_post__meta inbox"><div class="related_article__ttl ttl"><span class="labeltext">関連記事</span>画像圧縮・最適化プラグインEWWW Image Optimizerの使い方・設定方法まとめ</div><time class="time__date gf undo">2020.04.20</time></div></a></div>
<div class="related_article typesimple"><a class="related_article__link no-icon" href="https://tekito-style.me/columns/wordpress-image-webp"><figure class="eyecatch of-cover thum"><img loading="lazy" decoding="async" width="485" height="283" src="https://tekito-style.me/wp-content/uploads/2019/09/th_th_webp-too-485x283.jpg" class="archives-eyecatch-image attachment-oc-post-thum wp-post-image" alt="" srcset="https://tekito-style.me/wp-content/uploads/2019/09/th_th_webp-too-485x283.jpg 485w, https://tekito-style.me/wp-content/uploads/2019/09/th_th_webp-too-300x175.jpg 300w, https://tekito-style.me/wp-content/uploads/2019/09/th_th_webp-too-768x448.jpg 768w, https://tekito-style.me/wp-content/uploads/2019/09/th_th_webp-too-1024x597.jpg 1024w, https://tekito-style.me/wp-content/uploads/2019/09/th_th_webp-too.jpg 1200w" sizes="(max-width: 485px) 45vw, 485px" /></figure><div class="related_article__meta archives_post__meta inbox"><div class="related_article__ttl ttl"><span class="labeltext">関連記事</span>WordPressサイトで画像をWebP（ウェッピー）対応し軽量化する方法</div><time class="time__date gf undo">2020.04.20</time></div></a></div>
<div class="related_article typesimple"><a class="related_article__link no-icon" href="https://tekito-style.me/columns/wordpress-plugin-bj-lazyload"><figure class="eyecatch of-cover thum"><img loading="lazy" decoding="async" width="485" height="283" src="https://tekito-style.me/wp-content/uploads/2019/10/th_lazyload_top_1014-2-485x283.jpg" class="archives-eyecatch-image attachment-oc-post-thum wp-post-image" alt="" srcset="https://tekito-style.me/wp-content/uploads/2019/10/th_lazyload_top_1014-2-485x283.jpg 485w, https://tekito-style.me/wp-content/uploads/2019/10/th_lazyload_top_1014-2-300x175.jpg 300w, https://tekito-style.me/wp-content/uploads/2019/10/th_lazyload_top_1014-2-768x448.jpg 768w, https://tekito-style.me/wp-content/uploads/2019/10/th_lazyload_top_1014-2-1024x597.jpg 1024w, https://tekito-style.me/wp-content/uploads/2019/10/th_lazyload_top_1014-2.jpg 1200w" sizes="(max-width: 485px) 45vw, 485px" /></figure><div class="related_article__meta archives_post__meta inbox"><div class="related_article__ttl ttl"><span class="labeltext">関連記事</span>画像の遅延読み込みをするWPプラグインBJ Lazy Loadの使い方・設定方法まとめ</div><time class="time__date gf undo">2020.04.20</time></div></a></div>
<p>またサイトスピード改善で実施した施策とスコアの検証結果については、下記の記事で全てまとめていくので、よかったら施策の参考にしてみてください。<br />
<div class="related_article typesimple"><a class="related_article__link no-icon" href="https://tekito-style.me/columns/wordpress-sitespeed"><figure class="eyecatch of-cover thum"><img loading="lazy" decoding="async" width="485" height="283" src="https://tekito-style.me/wp-content/uploads/2019/11/th_wordpress-speed-up_1130-485x283.jpg" class="archives-eyecatch-image attachment-oc-post-thum wp-post-image" alt="" srcset="https://tekito-style.me/wp-content/uploads/2019/11/th_wordpress-speed-up_1130-485x283.jpg 485w, https://tekito-style.me/wp-content/uploads/2019/11/th_wordpress-speed-up_1130-300x175.jpg 300w, https://tekito-style.me/wp-content/uploads/2019/11/th_wordpress-speed-up_1130-768x448.jpg 768w, https://tekito-style.me/wp-content/uploads/2019/11/th_wordpress-speed-up_1130-1024x597.jpg 1024w, https://tekito-style.me/wp-content/uploads/2019/11/th_wordpress-speed-up_1130.jpg 1200w" sizes="(max-width: 485px) 45vw, 485px" /></figure><div class="related_article__meta archives_post__meta inbox"><div class="related_article__ttl ttl"><span class="labeltext">関連記事</span>WordPressのサイトスピード改善で実施した12の施策とスコア結果まとめ</div><time class="time__date gf">2019.11.30</time></div></a></div>
<p>下記記事では、WordPressのおすすめプラグインを厳選して紹介しています ↓↓<br />
<div class="related_article typesimple"><a class="related_article__link no-icon" href="https://tekito-style.me/columns/wordpress-plugins-roundup"><figure class="eyecatch of-cover thum"><img loading="lazy" decoding="async" width="485" height="283" src="https://tekito-style.me/wp-content/uploads/2020/04/91-wp-plugin-top-485x283.png" class="archives-eyecatch-image attachment-oc-post-thum wp-post-image" alt="" srcset="https://tekito-style.me/wp-content/uploads/2020/04/91-wp-plugin-top-485x283.png 485w, https://tekito-style.me/wp-content/uploads/2020/04/91-wp-plugin-top-1536x896.png 1536w, https://tekito-style.me/wp-content/uploads/2020/04/91-wp-plugin-top-2048x1195.png 2048w, https://tekito-style.me/wp-content/uploads/2020/04/91-wp-plugin-top-300x175.png 300w, https://tekito-style.me/wp-content/uploads/2020/04/91-wp-plugin-top-768x448.png 768w, https://tekito-style.me/wp-content/uploads/2020/04/91-wp-plugin-top-1024x597.png 1024w" sizes="(max-width: 485px) 45vw, 485px" /></figure><div class="related_article__meta archives_post__meta inbox"><div class="related_article__ttl ttl"><span class="labeltext">関連記事</span>おすすめ＆定番のWordPressプラグイン12選まとめ</div><time class="time__date gf undo">2020.07.14</time></div></a></div>The post <a href="https://tekito-style.me/columns/wordpress-plugin-fastest-cache">WP Fastest Cacheの使い方・設定方法【キャッシュ改善のおすすめプラグイン】</a> first appeared on <a href="https://tekito-style.me">Tekito style.me</a>.]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>画像の遅延読み込みをするWPプラグインBJ Lazy Loadの使い方・設定方法まとめ</title>
		<link>https://tekito-style.me/columns/wordpress-plugin-bj-lazyload</link>
		
		<dc:creator><![CDATA[やすのり]]></dc:creator>
		<pubDate>Mon, 14 Oct 2019 07:36:29 +0000</pubDate>
				<category><![CDATA[Webマーケティング]]></category>
		<category><![CDATA[WordPress/ブログ運営]]></category>
		<category><![CDATA[WordPressプラグイン]]></category>
		<category><![CDATA[サイトスピード改善]]></category>
		<guid isPermaLink="false">https://tekito-style.me/?p=3881</guid>

					<description><![CDATA[<p>WordPressのサイトスピード改善で対策すべきなのが、画像の遅延読み込み（Lazy Load）。画像データは重く一気に読む込むと表示スピードに影響するので、画像を読み込むタイミングを調整することでサイトスピードを改善...</p>
The post <a href="https://tekito-style.me/columns/wordpress-plugin-bj-lazyload">画像の遅延読み込みをするWPプラグインBJ Lazy Loadの使い方・設定方法まとめ</a> first appeared on <a href="https://tekito-style.me">Tekito style.me</a>.]]></description>
										<content:encoded><![CDATA[<p><!--


<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/10/th_lazyload_top_1014-2.jpg" alt="BJ Lazy Load"></p>



--><div class="voice cf l "><figure class="icon"><img loading="lazy" decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_th_IMG_0018_circle.jpg" class="voice_icon__img" width="150" height="150"><figcaption class="name">やすのり</figcaption></figure><div class="voicecomment">こんにちは！「Tekito style」を運営している<a href="https://twitter.com/98nasi_nori" target="_blank" rel="noopener noreferrer">やすのり（@98nasi_nori）</a>です。普段は都内でWebディレクター/マーケターなどをしています。</div></div>
WordPressのサイトスピード改善で対策すべきなのが、<span class="fwb">画像の遅延読み込み</span>（Lazy Load）。画像データは重く一気に読む込むと表示スピードに影響するので、画像を読み込むタイミングを調整することでサイトスピードを改善できます。</p>
<p><span class="fwb">そこで便利なプラグインが「BJ Lazy Load」。導入することで簡単に遅延読み込み機能を実装できます。</span>。</p>
<p>今回はBJ Lazy Loadの使い方や注意点などを解説していくので、遅延読み込み機能を検討している方はぜひチェックしてみてください。</p>
<div class="cbox intitle is-style-red_box type_normal"><div class="box_title"><span class="span__box_title">ネイティブLazy-loadについて</span></div><div class="cboxcomment">
※先日ネイティブLazy-loadをWordPressで簡単実装するプラグインをGoogleが公開しました。Google提供のプラグインなので、これから導入を検討される方はこちらを実装した方が良さそうです。ただ僕も別のサイトで使ってみましたが、<a href="https://developers.google.com/speed/pagespeed/insights/" target="_blank" rel="noopener noreferrer">PageSpeed Insights</a>の結果に反映されていない場合もあったので、テストしつつ様子を見てみた方が良さそうです。僕も順次こっちのプラグインに移行する予定です。<br />
<a href="https://ja.wordpress.org/plugins/native-lazyload/" target="_blank" rel="noopener noreferrer"><br />
Native Lazyload</a><br />
</div></div>
<h2>BJ Lazy Loadってどんなプラグイン？</h2>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/10/th_1_BJLazyLoad_1013_2019.jpg" alt="BJ Lazy Load"><br />
<span class="fs13 fcNote">photo by：<a href="https://wordpress.org/plugins/bj-lazy-load/" target="_blank" rel="noopener noreferrer">WordPress公式サイト</a></span></p>
<p>BJ Lazy Loadは画像の遅延読み込みを簡単に実装できるWordPressプラグイン。画面に画像を表示するタイミングで画像データを読み込む設定ができます。一気に画像データを読み込む必要がなくなるので、サイトの表示スピード改善が期待できます。</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/10/th_2_BJLazyLoad_1013_2019.jpg" alt="PageSpeed Insights"></p>
<p>Googleが提供するサイトスピード計測ツール「PageSpeed Insights」で提案される改善項目で、「オフスクリーン画像の遅延読み込み」と出るのがそれです。</p>
<p>また遅延読み込み対策ができるプラグインは、以下のように色々と種類があります。</p>
<ul>
<li>Lazy Load</li>
<li>BJ Lazy Load</li>
<li>a3 Lazy Load</li>
<li>Lazy Load by WP Rocket</li>
<li>Lazy Load Optimizer</li>
</ul>
<p>ただしプラグインによっては、<span class="fwb">利用しているテーマと相性が悪い場合があります</span>。現在僕が使っているテーマ「ストーク」だと正常に動作しないと指摘されているプラグインもあったので、今回は事前にリサーチし問題なさそうな「BJ Lazy Load」を選定しました。</p>
<h3>BJ Lazy Loadで遅延読み込み設定できる項目</h3>
<p>BJ Lazy Loadでは、以下の要素の遅延読み込み対応が可能です。コンテンツ内の画像データ以外にも、サムネイルや重くなりがちなiframeタグの遅延読み込みも可能です。</p>
<ul>
<li>コンテンツ</li>
<li>テキストウィジェット</li>
<li>投稿サムネイル</li>
<li>グラバター</li>
<li>画像</li>
<li>iframe</li>
</ul>
<p><a href="https://wordpress.org/plugins/bj-lazy-load/" target="_blank" rel="noopener noreferrer">BJ Lazy Load</a></p>
<h2>BJ Lazy Loadの導入方法</h2>
<p>BJ Lazy Loadの導入方法を確認していきましょう！他のWordPressプラグインと手順は同じです。</p>
<h3>インストールと有効化</h3>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/10/th_3_BJLazyLoad_1013_2019.jpg" alt="BJ Lazy Load"></p>
<p>管理画面のメニュー「プラグイン」&gt;「新規追加」から、「BJ Lazy Load」で検索。「いますぐインストール」をクリックし、有効化します。</p>
<h3>設定欄からインストールされてるか確認</h3>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/10/th_4_BJLazyLoad_1013_2019.png" alt="BJ Lazy Load"></p>
<p>インストールを完了すると、管理画面の設定欄に「BJ Lazy Load」が追加されていればOKです。クリックして詳細を確認しましょう。</p>
<h2>BJ Lazy Loadの使い方・設定方法</h2>
<p>BJ Lazy Loadの使い方や設定方法はかなりシンプルです。一つ一つ確認していきましょう。</p>
<h3>基本設定</h3>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/10/th_5_BJLazyLoad_1013_2019.jpg" alt="BJ Lazy Loadの設定画面"></p>
<p><span class="fwb">基本的に全ての項目に「YES」で問題ないです</span>。下記の項目にLazy loadが実装されます。</p>
<ul>
<li>Apply to content（記事内の画像）</li>
<li>Apply to text widgets（ウィジットの画像）</li>
<li>Apply to post thumbnails（サムネイル画像）</li>
<li>Apply to gravatars（アバター画像）</li>
<li>Lazy load images（画像の遅延読み込み）</li>
<li>Lazy load iframes（iframeタグの遅延読み込み）</li>
</ul>
<h3>追加設定</h3>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/10/th_6_BJLazyLoad_1013_2019.jpg" alt="BJ Lazy Loadの設定画面"></p>
<p>もう少し細かい設定もできるので、確認していきましょう。</p>
<h4>Placeholder Image URL</h4>
<p>画像が表示されるまで、仮の画像を表示する設定ができます。特に設定しなくてもOKかなと思います。必要であれば、仮画像のURLを設定しておきましょう。</p>
<h4>Skip images with classes</h4>
<p><span class="fwb">特定のクラスが付与されている画像を、遅延読み込みの対象から除外できます</span>。</p>
<p>例えば僕の使っているテーマstorkでは、ファーストビューで表示される画像やロゴ画像の読み込みが遅くなると、体感的に表示される速度が遅くなり微妙な感じになりました。ですのでそこだけ「no-bj-lazy」というクラスを割り当てて、遅延読み込みを解除しています。</p>
<p>遅延解除のために新規でクラスを追加するだけでなく、既存のクラスも指定できるので便利ですね。</p>
<div class="cbox intitle is-style-blue_box type_normal"><div class="box_title"><span class="span__box_title">メモ：アイキャッチ画像のみ解除する場合</span></div><div class="cboxcomment">
使っているテーマにもよりますが、　Storkでアイキャッチ画像の遅延読み込みを解除した場合は下記のようにソースコードを変更します。</p>
<p>「single.php」ファイルの43行目<br />
<!--?php the_post_thumbnail(); ?--><br />
→<br />
<!--?php the_post_thumbnail( 'post-thumbnail', 'class=no-bj-lazy' ); ?--></p>
<p>【参考記事】<br />
・the_post_thumbnail<br />
<a href="https://elearn.jp/wpman/function/the_post_thumbnail.html" target="_blank" rel="noopener noreferrer">https://elearn.jp/wpman/function/the_post_thumbnail.html</a></p>
<p>※まだ未確認ですが、シンプルに「Apply to post thumbnails」の項目のチェックを外すだけでいけるかもです……！<br />
</div></div>
<h4>Threshold</h4>
<p>画像を読み込ませるタイミングを指定することができます（単位はピクセル）。例えば100とかに設定すると、画像が表示される100px手前で読み込みが開始されるので、かなり直前で読み込まれることになります。</p>
<p>逆に1,000とかだと、画像が表示されるずっと前に読み込まれることになります（あまりLazy Loadの意味がなくなる）。</p>
<p>デフォルトだと200ですが、<span class="fwb">早く画面をスクロールすると画像表示の挙動が遅く感じるので、僕は500に設定しています</span>。</p>
<p>ある程度ゆとりをもたせて先に読み込ませた方が、自然な挙動でストレスなく画像の表示ができますよ。</p>
<h4>Use low-res preview image</h4>
<p>実際の画像が完全に読み込まれるまでに、同一画像で画質が低いものを先に表示できる設定。まず低画質の画像を読み込んで、高画質の画像を読み込む感じですね。</p>
<p>僕は特に設定していませんが、必要であれば調整してみてください。またこの設定を有効化する以前アップロードされた画像は、画像サイズを再生成する必要があります。</p>
<h3>Google botのクロール対応</h3>
<p>遅延読み込みを実装した場合、懸念されるのがSEOへのマイナスな影響が発生する可能性があること。</p>
<p><span class="fwb">遅延読み込みの設定をした場合、遅延読み込みされる画像データが適切にGoogleのbotにクロールされない場合があります</span>。つまり画像データがコンテンツ内にあるとGoogleに正しく認識されないということです。</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/10/th_7_BJLazyLoad_1013_2019.jpg" alt="サーチコンソール"></p>
<p>一応サーチコンソールで確認してみましたが、BJ Lazy Load導入後何やらエラーが発生していました。ライブテストで画像のレンダリングも上手くできていませんでした。</p>
<p>ですのでクロールエラーを回避し、遅延読み込みする画像をクロールされるために、プラグインのソースコードを少し調整する必要があります。</p>
<h4>BJ Lazy Loadの編集</h4>
<p>WordPress管理画面のサイドバー「プラグイン」欄から、「プラグインエディター」 を選択します。</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/10/th_9_BJLazyLoad_1013_2019.jpg" alt="BJ Lazy Loadの編集画面"></p>
<p>今回編集するプラグイン「BJ Lazy Load」を選択し、incフォルダをクリック。</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/10/th_10_BJLazyLoad_1013_2019.jpg" alt="BJ Lazy Loadの編集画面"></p>
<p>incフォルダ内に「class.bjll.php」というファイルがあるので、45行目にあるコードを下記の用に変更します。</p>
<div class="cbox intitle is-style-blue_box type_normal"><div class="box_title"><span class="span__box_title">変更前のコード</span></div><div class="cboxcomment">
<pre><code>
	/* We do not touch the feeds */
	if ( is_feed() ) {
		return;
	}</code></pre>
</div></div>
<div class="cbox intitle is-style-blue_box type_normal"><div class="box_title"><span class="span__box_title">変更後のコード</span></div><div class="cboxcomment">
<pre><code>
	/* We do not touch the feeds */
	if ( is_feed() || stripos($_SERVER['HTTP_USER_AGENT'], 'Googlebot')) {
		return;
	}</code></pre>
</div></div>
<p>変更できたら「ファイルを更新」ボタンをクリックし保存します。</p>
<h4>管理画面で変更できない場合は、FTPソフトで編集</h4>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/10/th_11_BJLazyLoad_1013_2019.jpg" alt="BJ Lazy Loadの編集画面"></p>
<p>WordPressの管理画面上では、プラグインの変更許可が下りない場合があります。そのときはFTPソフトで同様の変更をすればOKです！</p>
<div class="supplement boader">
/home/◯◯◯/www/wp/wp-content/plugins/bj-lazy-load/inc<br />
</div>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/10/th_12_BJLazyLoad_1013_2019.jpg" alt="FTP"></p>
<p>上記のパスにアクセスし、「class.bjll.php」ファイルを同様に発見したらダウンロードします。</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/10/th_13_BJLazyLoad_1013_2019.jpg" alt="FTP"></p>
<p>テキストエディタで同様にソースコードを編集し保存、その後アップロードして上書き保存すれば完了ですね！</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/10/th_15_BJLazyLoad_1013_2019.jpg" alt="サーチコンソール"></p>
<p>再度サーチコンソールで確認してみると、問題なくクロールできていました！画像のレンダリングもできているようです。良かった〜！</p>
<h2>BJ Lazy Loadを有効活用しよう！</h2>
<p>BJ Lazy Loadを活用して遅延読み込み機能を実装してきましたが、いかがでしょうか？プラグインの操作・設定自体は難しくないのですが、少しコードの調整が必要ではあります。</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/10/th_16_BJLazyLoad_1013_2019.jpg" alt="PageSpeed Insights"></p>
<p>実際にPageSpeed Insightsで再度サイトスピードの検証をしてみると、「オフスクリーン画像の遅延読み込み」の項目が合格し、スマフォ版サイトのスコアが20くらい上がりました！体感的にも表示速度が早くなっているので、プラグインを導入した甲斐はありましたね。</p>
<p>それでは！</p>
<p>画像の最適化対策については、以下のWordPressプラグインも参考にしてみてくださいね。<br />
<div class="related_article typesimple"><a class="related_article__link no-icon" href="https://tekito-style.me/columns/wordpress-plugin-eww-imageoptimizer"><figure class="eyecatch of-cover thum"><img loading="lazy" decoding="async" width="485" height="287" src="https://tekito-style.me/wp-content/uploads/2019/09/th_0_EWWWImageOptimizer-485x287.png" class="archives-eyecatch-image attachment-oc-post-thum wp-post-image" alt="" srcset="https://tekito-style.me/wp-content/uploads/2019/09/th_0_EWWWImageOptimizer-485x287.png 485w, https://tekito-style.me/wp-content/uploads/2019/09/th_0_EWWWImageOptimizer-300x178.png 300w, https://tekito-style.me/wp-content/uploads/2019/09/th_0_EWWWImageOptimizer-768x454.png 768w, https://tekito-style.me/wp-content/uploads/2019/09/th_0_EWWWImageOptimizer.png 1014w" sizes="(max-width: 485px) 45vw, 485px" /></figure><div class="related_article__meta archives_post__meta inbox"><div class="related_article__ttl ttl"><span class="labeltext">関連記事</span>画像圧縮・最適化プラグインEWWW Image Optimizerの使い方・設定方法まとめ</div><time class="time__date gf undo">2020.04.20</time></div></a></div>
<div class="related_article typesimple"><a class="related_article__link no-icon" href="https://tekito-style.me/columns/wordpress-image-webp"><figure class="eyecatch of-cover thum"><img loading="lazy" decoding="async" width="485" height="283" src="https://tekito-style.me/wp-content/uploads/2019/09/th_th_webp-too-485x283.jpg" class="archives-eyecatch-image attachment-oc-post-thum wp-post-image" alt="" srcset="https://tekito-style.me/wp-content/uploads/2019/09/th_th_webp-too-485x283.jpg 485w, https://tekito-style.me/wp-content/uploads/2019/09/th_th_webp-too-300x175.jpg 300w, https://tekito-style.me/wp-content/uploads/2019/09/th_th_webp-too-768x448.jpg 768w, https://tekito-style.me/wp-content/uploads/2019/09/th_th_webp-too-1024x597.jpg 1024w, https://tekito-style.me/wp-content/uploads/2019/09/th_th_webp-too.jpg 1200w" sizes="(max-width: 485px) 45vw, 485px" /></figure><div class="related_article__meta archives_post__meta inbox"><div class="related_article__ttl ttl"><span class="labeltext">関連記事</span>WordPressサイトで画像をWebP（ウェッピー）対応し軽量化する方法</div><time class="time__date gf undo">2020.04.20</time></div></a></div>
<p>またサイトスピード改善で実施した施策とスコアの検証結果については、下記の記事で全てまとめていくので、よかったら施策の参考にしてみてください。<br />
<div class="related_article typesimple"><a class="related_article__link no-icon" href="https://tekito-style.me/columns/wordpress-sitespeed"><figure class="eyecatch of-cover thum"><img loading="lazy" decoding="async" width="485" height="283" src="https://tekito-style.me/wp-content/uploads/2019/11/th_wordpress-speed-up_1130-485x283.jpg" class="archives-eyecatch-image attachment-oc-post-thum wp-post-image" alt="" srcset="https://tekito-style.me/wp-content/uploads/2019/11/th_wordpress-speed-up_1130-485x283.jpg 485w, https://tekito-style.me/wp-content/uploads/2019/11/th_wordpress-speed-up_1130-300x175.jpg 300w, https://tekito-style.me/wp-content/uploads/2019/11/th_wordpress-speed-up_1130-768x448.jpg 768w, https://tekito-style.me/wp-content/uploads/2019/11/th_wordpress-speed-up_1130-1024x597.jpg 1024w, https://tekito-style.me/wp-content/uploads/2019/11/th_wordpress-speed-up_1130.jpg 1200w" sizes="(max-width: 485px) 45vw, 485px" /></figure><div class="related_article__meta archives_post__meta inbox"><div class="related_article__ttl ttl"><span class="labeltext">関連記事</span>WordPressのサイトスピード改善で実施した12の施策とスコア結果まとめ</div><time class="time__date gf">2019.11.30</time></div></a></div>
<p>下記記事では、WordPressのおすすめプラグインを厳選して紹介しています ↓↓<br />
<div class="related_article typesimple"><a class="related_article__link no-icon" href="https://tekito-style.me/columns/wordpress-plugins-roundup"><figure class="eyecatch of-cover thum"><img loading="lazy" decoding="async" width="485" height="283" src="https://tekito-style.me/wp-content/uploads/2020/04/91-wp-plugin-top-485x283.png" class="archives-eyecatch-image attachment-oc-post-thum wp-post-image" alt="" srcset="https://tekito-style.me/wp-content/uploads/2020/04/91-wp-plugin-top-485x283.png 485w, https://tekito-style.me/wp-content/uploads/2020/04/91-wp-plugin-top-1536x896.png 1536w, https://tekito-style.me/wp-content/uploads/2020/04/91-wp-plugin-top-2048x1195.png 2048w, https://tekito-style.me/wp-content/uploads/2020/04/91-wp-plugin-top-300x175.png 300w, https://tekito-style.me/wp-content/uploads/2020/04/91-wp-plugin-top-768x448.png 768w, https://tekito-style.me/wp-content/uploads/2020/04/91-wp-plugin-top-1024x597.png 1024w" sizes="(max-width: 485px) 45vw, 485px" /></figure><div class="related_article__meta archives_post__meta inbox"><div class="related_article__ttl ttl"><span class="labeltext">関連記事</span>おすすめ＆定番のWordPressプラグイン12選まとめ</div><time class="time__date gf undo">2020.07.14</time></div></a></div>The post <a href="https://tekito-style.me/columns/wordpress-plugin-bj-lazyload">画像の遅延読み込みをするWPプラグインBJ Lazy Loadの使い方・設定方法まとめ</a> first appeared on <a href="https://tekito-style.me">Tekito style.me</a>.]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>Autoptimizeの使い方・設定方法を解説【CSSやJSを最適化するWPプラグイン】</title>
		<link>https://tekito-style.me/columns/wordpress-plugin-autoptimize</link>
		
		<dc:creator><![CDATA[やすのり]]></dc:creator>
		<pubDate>Sun, 06 Oct 2019 10:54:57 +0000</pubDate>
				<category><![CDATA[Webマーケティング]]></category>
		<category><![CDATA[WordPress/ブログ運営]]></category>
		<category><![CDATA[WordPressプラグイン]]></category>
		<category><![CDATA[サイトスピード改善]]></category>
		<guid isPermaLink="false">https://tekito-style.me/?p=3862</guid>

					<description><![CDATA[<p>WordPressのサイトスピード改善では、画像ファイルの最適化の他にも、HTMLやCSS、Javascriptなどのリソースを最適化することで一定の効果が見込めます。 そこで便利なプラグインが「Autoptimize」...</p>
The post <a href="https://tekito-style.me/columns/wordpress-plugin-autoptimize">Autoptimizeの使い方・設定方法を解説【CSSやJSを最適化するWPプラグイン】</a> first appeared on <a href="https://tekito-style.me">Tekito style.me</a>.]]></description>
										<content:encoded><![CDATA[<p><!--


<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/10/Autoptimize_top_1006.png" alt="Autoptimize"></p>



--><div class="voice cf l "><figure class="icon"><img loading="lazy" decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_th_IMG_0018_circle.jpg" class="voice_icon__img" width="150" height="150"><figcaption class="name">やすのり</figcaption></figure><div class="voicecomment">こんにちは！「Tekito style」を運営している<a href="https://twitter.com/98nasi_nori" target="_blank" rel="noopener noreferrer">やすのり（@98nasi_nori）</a>です。普段は都内でWebディレクター/マーケターなどをしています。</div></div>
WordPressのサイトスピード改善では、<a href="https://tekito-style.me/columns/wordpress-plugin-eww-imageoptimizer">画像ファイルの最適化</a>の他にも、HTMLやCSS、Javascriptなどのリソースを最適化することで一定の効果が見込めます。</p>
<p><span class="fwb">そこで便利なプラグインが「Autoptimize」。主要なリソースを簡単に軽量化・圧縮してくれるツールです</span>。</p>
<p>今回はAutoptimizeの使い方や注意点などを解説していくので、サイトスピード改善を検討している方はぜひチェックしてみてください。</p>
<h2>Autoptimizeってどんなプラグイン？</h2>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/10/th_0Autoptimize.jpg" alt="Autoptimize"><br />
<span class="fs13 fcNote">photo by：<a href="https://ja.wordpress.org/plugins/autoptimize/" target="_blank" rel="noopener noreferrer">公式サイト</a></span></p>
<p>Autoptimizeは、CSSやJSなどのリソースを軽量・最適化してくれるプラグイン。</p>
<p><span class="fwb">改行やスペースを削除してくれたり、複数のファイルを結合して圧縮してくれたりと、これ1つで便利な機能を備えています</span>。利用は無料です。</p>
<p>実際に僕も使ってみて、Googleが提供するサイトスピード計測ができる「<a href="https://developers.google.com/speed/pagespeed/insights/?hl=ja" target="_blank" rel="noopener noreferrer">PageSpeed Insight</a>」で計測しました。するとスマフォ版の「レンダリングを妨げるリソースの除外」の項目が、</p>
<p>改修前：1.25ss → 改修度：0.64ss</p>
<p>まで下がったので、導入した効果は結構あったかなと思います。</p>
<p><a href="https://ja.wordpress.org/plugins/autoptimize/" target="_blank" rel="noopener noreferrer">Autoptimize</a></p>
<h2>Autoptimizeの導入方法</h2>
<p>Autoptimizeの導入方法を見ていきましょう！他のWordPressプラグインと同じ導入手順です。</p>
<h3>インストールと有効化</h3>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/10/th_1Autoptimize.jpg" alt="Autoptimize"></p>
<p>管理画面のメニュー「プラグイン」&gt;「新規追加」から、「Autoptimize」で検索。「いますぐインストール」をクリックし、有効化します。</p>
<h3>設定欄からインストールされてるか確認</h3>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/10/th_2Autoptimize.png" alt="Autoptimize"></p>
<p>インストールを完了すると、管理画面の設定欄に「Autoptimize」が追加されています。クリックし詳細の設定欄を確認しましょう。</p>
<h2>Autoptimizeの使い方・設定方法</h2>
<p>Autoptimizeの使い方、設定方法を確認していきましょう。</p>
<h3>JS,CSS &amp; HTMLタブ</h3>
<p>まずはメインの設定事項となる、「JS,CSS &amp; HTML」タブから確認します。</p>
<h4>JavaScript オプション</h4>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/10/th_3Autoptimize.jpg" alt="Autoptimize"></p>
<p>ここではJavaScriptの設定が可能です。基本的に以下の2つの項目を選択すればOKです。</p>
<div class="supplement boader">
<ul>
<li>JavaScript コードの最適化</li>
<li>Aggregate JS-files?</li>
</ul>
</div>
<p>これでJSコードから改行をなくして圧縮するなど、ファイルサイズを最適化してくれます。</p>
<div class="supplement boader">
<ul>
<li>&lt;head&gt; 内へ JavaScript を強制</li>
<li>try-catch の折り返しを追加</li>
</ul>
</div>
<p>上記の項目については、もしJSコードを最適化することでJSが動かなくなるなどエラーが発生した場合はチェックしてみましょう。</p>
<p>ただしhead内にJSコードを全て移動すると読み込みが遅くなるので、基本的にはおすすめしません。エラーを起こしているJSファイルに関しては、FTPソフトなどを使って個別にheadに移動するなど調整をしましょう。</p>
<h4>CSS オプション</h4>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/10/th_4Autoptimize.jpg" alt="Autoptimize"></p>
<p>CSSについては下記の項目をチェックするだけでOK。</p>
<div class="supplement boader">
<ul>
<li>CSS コードを最適化</li>
<li>Aggregate CSS-files?</li>
<li>インラインの CSS を連結</li>
</ul>
</div>
<p>他の要素を実行する場合は、動作やパファーマンスが実際に改善されるか、環境によっても異なるかと思うので個別に確認してみてください。</p>
<h4>HTML オプション</h4>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/10/th_5Autoptimize.jpg" alt="Autoptimize"></p>
<p>HTMLは下記の1項目をチェック。</p>
<div class="supplement boader">
<ul>
<li>HTML コードを最適化</li>
</ul>
</div>
<p>もしコメントをHTMLファイルにそのまま残したい場合は、「HTML コメントを残す」を選択します。</p>
<h4>その他オプション</h4>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/10/th_6Autoptimize.jpg" alt="Autoptimize"></p>
<p>下記の2項目をチェックします。</p>
<div class="supplement boader">
<ul>
<li>連結されたスクリプト / CSS を静的ファイルとして保存</li>
<li>Minify excluded CSS and JS files?</li>
</ul>
</div>
<p>サイトにログイン機能があれば、「ログイン中のユーザーも最適化しますか ?」も合わせてチェックしてみてください（特に機能がなければ不要）。</p>
<p>すべての内容に問題なければ、「変更を保存してキャッシュを削除」します。</p>
<h3>Imagesタブ</h3>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/10/th_9Autoptimize.jpg" alt="Autoptimize"></p>
<p>Imagesタブについては特に設定する必要はありません。Lazy-load（画像の遅延読み込み）もAutoptimizeで実装できるみたいですね。</p>
<p>もし他にLazy-load系のプラグインを使っている方は、チェックすると動作に問題が生じる可能性があります。僕は他のプラグインで実装しているので今回はスルー。</p>
<h3>追加タブ</h3>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/10/th_10Autoptimize.jpg" alt="Autoptimize"></p>
<p>追加タブに移り、下記項目にチェックします。</p>
<div class="supplement boader">
<ul>
<li>webfont.js で非同期にフォントを結合して読み込む</li>
<li>絵文字を削除</li>
</ul>
</div>
<p>フォントや絵文字のリソースもサイトスピードにやや影響するので、最適化しておくといいでしょう。</p>
<p>ただフォントに関しては、一度ブラウザのデフォルトのフォント &gt; Googleフォントの順で読み込まれる場合、やや切り替える時の動作がぎこちなくなる時があります。気になる方はチェックを外すといいかなと思います。</p>
<h3>さらに最適化！タブ</h3>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/10/th_11Autoptimize.jpg" alt="Autoptimize"></p>
<p>こちらについては有料機能やより硬度な機能になるので、特に設定しなくてOKです。</p>
<h2>Autoptimizeでリソースを最適化しよう！</h2>
<p>Autoptimizeはリソースの軽量化・最適化するのに、簡単で便利なプラグインです。WordPressのサイトスピード改善を進めている方は、ぜひ試してみてくださいね！</p>
<p>サイトスピード改善で重要な画像の最適化については下記記事も参考にしてみてください ↓↓<br />
<div class="related_article typesimple"><a class="related_article__link no-icon" href="https://tekito-style.me/columns/wordpress-plugin-eww-imageoptimizer"><figure class="eyecatch of-cover thum"><img loading="lazy" decoding="async" width="485" height="287" src="https://tekito-style.me/wp-content/uploads/2019/09/th_0_EWWWImageOptimizer-485x287.png" class="archives-eyecatch-image attachment-oc-post-thum wp-post-image" alt="" srcset="https://tekito-style.me/wp-content/uploads/2019/09/th_0_EWWWImageOptimizer-485x287.png 485w, https://tekito-style.me/wp-content/uploads/2019/09/th_0_EWWWImageOptimizer-300x178.png 300w, https://tekito-style.me/wp-content/uploads/2019/09/th_0_EWWWImageOptimizer-768x454.png 768w, https://tekito-style.me/wp-content/uploads/2019/09/th_0_EWWWImageOptimizer.png 1014w" sizes="(max-width: 485px) 45vw, 485px" /></figure><div class="related_article__meta archives_post__meta inbox"><div class="related_article__ttl ttl"><span class="labeltext">関連記事</span>画像圧縮・最適化プラグインEWWW Image Optimizerの使い方・設定方法まとめ</div><time class="time__date gf undo">2020.04.20</time></div></a></div>
<div class="related_article typesimple"><a class="related_article__link no-icon" href="https://tekito-style.me/columns/wordpress-image-webp"><figure class="eyecatch of-cover thum"><img loading="lazy" decoding="async" width="485" height="283" src="https://tekito-style.me/wp-content/uploads/2019/09/th_th_webp-too-485x283.jpg" class="archives-eyecatch-image attachment-oc-post-thum wp-post-image" alt="" srcset="https://tekito-style.me/wp-content/uploads/2019/09/th_th_webp-too-485x283.jpg 485w, https://tekito-style.me/wp-content/uploads/2019/09/th_th_webp-too-300x175.jpg 300w, https://tekito-style.me/wp-content/uploads/2019/09/th_th_webp-too-768x448.jpg 768w, https://tekito-style.me/wp-content/uploads/2019/09/th_th_webp-too-1024x597.jpg 1024w, https://tekito-style.me/wp-content/uploads/2019/09/th_th_webp-too.jpg 1200w" sizes="(max-width: 485px) 45vw, 485px" /></figure><div class="related_article__meta archives_post__meta inbox"><div class="related_article__ttl ttl"><span class="labeltext">関連記事</span>WordPressサイトで画像をWebP（ウェッピー）対応し軽量化する方法</div><time class="time__date gf undo">2020.04.20</time></div></a></div>
<p>またサイトスピード改善で実施した施策とスコアの検証結果については、下記の記事で全てまとめていくので、よかったら施策の参考にしてみてください。<br />
<div class="related_article typesimple"><a class="related_article__link no-icon" href="https://tekito-style.me/columns/wordpress-sitespeed"><figure class="eyecatch of-cover thum"><img loading="lazy" decoding="async" width="485" height="283" src="https://tekito-style.me/wp-content/uploads/2019/11/th_wordpress-speed-up_1130-485x283.jpg" class="archives-eyecatch-image attachment-oc-post-thum wp-post-image" alt="" srcset="https://tekito-style.me/wp-content/uploads/2019/11/th_wordpress-speed-up_1130-485x283.jpg 485w, https://tekito-style.me/wp-content/uploads/2019/11/th_wordpress-speed-up_1130-300x175.jpg 300w, https://tekito-style.me/wp-content/uploads/2019/11/th_wordpress-speed-up_1130-768x448.jpg 768w, https://tekito-style.me/wp-content/uploads/2019/11/th_wordpress-speed-up_1130-1024x597.jpg 1024w, https://tekito-style.me/wp-content/uploads/2019/11/th_wordpress-speed-up_1130.jpg 1200w" sizes="(max-width: 485px) 45vw, 485px" /></figure><div class="related_article__meta archives_post__meta inbox"><div class="related_article__ttl ttl"><span class="labeltext">関連記事</span>WordPressのサイトスピード改善で実施した12の施策とスコア結果まとめ</div><time class="time__date gf">2019.11.30</time></div></a></div>
<p>ブログやサイトのデザインについて悩んでいる方は、Webデザインスクールで学ぶのも選択肢の1つですよ ↓↓<br />
<div class="related_article typesimple"><a class="related_article__link no-icon" href="https://tekito-style.me/columns/webdesign-school-merit"><figure class="eyecatch of-cover thum"><img loading="lazy" decoding="async" width="485" height="364" src="https://tekito-style.me/wp-content/uploads/2021/06/th-th-webdesign-school-merit-top1-16.54.47-485x364.jpg" class="archives-eyecatch-image attachment-oc-post-thum wp-post-image" alt="" srcset="https://tekito-style.me/wp-content/uploads/2021/06/th-th-webdesign-school-merit-top1-16.54.47-485x364.jpg 485w, https://tekito-style.me/wp-content/uploads/2021/06/th-th-webdesign-school-merit-top1-16.54.47-300x225.jpg 300w, https://tekito-style.me/wp-content/uploads/2021/06/th-th-webdesign-school-merit-top1-16.54.47-768x576.jpg 768w, https://tekito-style.me/wp-content/uploads/2021/06/th-th-webdesign-school-merit-top1-16.54.47.jpg 800w" sizes="(max-width: 485px) 45vw, 485px" /></figure><div class="related_article__meta archives_post__meta inbox"><div class="related_article__ttl ttl"><span class="labeltext">関連記事</span>Webデザインスクール・専門学校に通うメリット・デメリットを経験者が比較してみた</div><time class="time__date gf undo">2023.09.30</time></div></a></div>
<p>下記記事では、WordPressのおすすめプラグインを厳選して紹介しています ↓↓<br />
<div class="related_article typesimple"><a class="related_article__link no-icon" href="https://tekito-style.me/columns/wordpress-plugins-roundup"><figure class="eyecatch of-cover thum"><img loading="lazy" decoding="async" width="485" height="283" src="https://tekito-style.me/wp-content/uploads/2020/04/91-wp-plugin-top-485x283.png" class="archives-eyecatch-image attachment-oc-post-thum wp-post-image" alt="" srcset="https://tekito-style.me/wp-content/uploads/2020/04/91-wp-plugin-top-485x283.png 485w, https://tekito-style.me/wp-content/uploads/2020/04/91-wp-plugin-top-1536x896.png 1536w, https://tekito-style.me/wp-content/uploads/2020/04/91-wp-plugin-top-2048x1195.png 2048w, https://tekito-style.me/wp-content/uploads/2020/04/91-wp-plugin-top-300x175.png 300w, https://tekito-style.me/wp-content/uploads/2020/04/91-wp-plugin-top-768x448.png 768w, https://tekito-style.me/wp-content/uploads/2020/04/91-wp-plugin-top-1024x597.png 1024w" sizes="(max-width: 485px) 45vw, 485px" /></figure><div class="related_article__meta archives_post__meta inbox"><div class="related_article__ttl ttl"><span class="labeltext">関連記事</span>おすすめ＆定番のWordPressプラグイン12選まとめ</div><time class="time__date gf undo">2020.07.14</time></div></a></div>The post <a href="https://tekito-style.me/columns/wordpress-plugin-autoptimize">Autoptimizeの使い方・設定方法を解説【CSSやJSを最適化するWPプラグイン】</a> first appeared on <a href="https://tekito-style.me">Tekito style.me</a>.]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>WordPressサイトで画像をWebP（ウェッピー）対応し軽量化する方法</title>
		<link>https://tekito-style.me/columns/wordpress-image-webp</link>
		
		<dc:creator><![CDATA[やすのり]]></dc:creator>
		<pubDate>Sat, 28 Sep 2019 12:18:03 +0000</pubDate>
				<category><![CDATA[Webマーケティング]]></category>
		<category><![CDATA[WordPress/ブログ運営]]></category>
		<category><![CDATA[デザイン・開発]]></category>
		<category><![CDATA[WordPress]]></category>
		<category><![CDATA[サイトスピード改善]]></category>
		<guid isPermaLink="false">https://tekito-style.me/?p=3835</guid>

					<description><![CDATA[<p>サイトスピード改善でもっともネックになるのが画像。画像データは基本的に重いので、圧縮するなどできる限り軽量化することが望ましいです。 そこでぜひ試してみたかったのが、画像のWebP（ウェッピー）対応をすること。WebPは...</p>
The post <a href="https://tekito-style.me/columns/wordpress-image-webp">WordPressサイトで画像をWebP（ウェッピー）対応し軽量化する方法</a> first appeared on <a href="https://tekito-style.me">Tekito style.me</a>.]]></description>
										<content:encoded><![CDATA[<p><!--


<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_th_webp-too.jpg" alt="WordPressサイトで画像をWebP（ウェッピー）対応する方法"></p>



--><div class="voice cf l "><figure class="icon"><img loading="lazy" decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_th_IMG_0018_circle.jpg" class="voice_icon__img" width="150" height="150"><figcaption class="name">やすのり</figcaption></figure><div class="voicecomment">こんにちは！「Tekito style」を運営している<a href="https://twitter.com/98nasi_nori" target="_blank" rel="noopener noreferrer">やすのり（@98nasi_nori）</a>です。普段は都内でWebディレクター/マーケターなどをしています。</div></div>
<p>サイトスピード改善でもっともネックになるのが画像。画像データは基本的に重いので、圧縮するなどできる限り軽量化することが望ましいです。</p>
<p>そこでぜひ試してみたかったのが、画像のWebP（ウェッピー）対応をすること。<span class="fwb">WebPはGoogleが開発・推奨している最新の画像形式で、画像の軽量化を期待できます</span>。</p>
<p>WordPressサイトの場合ですと、プラグインを使えば比較的簡単にWebPに対応することができます。今回はWordPressサイトにおける画像のWebP化の設定方法や注意点などを解説していくので、サイトスピード改善を検討している方はぜひチェックしてみてください。</p>
<h2>WebP（ウェッピー）ってどんな規格？</h2>
<p>WebP（ウェッピー）はGoogleが開発し導入を推奨している静止画像フォーマット。拡張子はそのまま「◯◯◯.webp」となります。</p>
<p><span class="fwb">JPEGなど従来の画像フォーマットと比較すると、2〜3割近く画像を軽量化することができます</span>。</p>
<blockquote><p>
<span class="fwb">A new image format for the Web</span><br />
WebP lossless images are 26% smaller in size compared to PNGs. WebP lossy images are 25-34% smaller than comparable JPEG images at equivalent SSIM quality index.</p>
<p>（<span class="fwb">Web用の新しい画像形式</span><br />
WebPでロスレス圧縮（可逆圧縮）された画像は、PNGと比較してファイルサイズが26％小さくなります。またWebPで非可逆圧縮された画像は、JPEGの場合、同等のSSIM品質指標の画像よりも25〜34％サイズが小さくなります。）<br />
<quote class="fs13 fcNote">by：<a href="https://developers.google.com/speed/webp" target="_blank" rel="noopener noreferrer">https://developers.google.com/speed/webp</a></quote></p></blockquote>
<p><!--


<blockquote>
Googleの示した事例では、ファイルサイズは非可逆圧縮モードで（同一画像、同等画質の）JPEGと比較して25-34%小さくなり、可逆圧縮モードでPNGと比較して28%小さくなるとしている。また22%のファイルサイズ増加でアルファチャネルを追加できるとしている。
<quote class="fs13 fcNote">by：<a href="https://ja.wikipedia.org/wiki/WebP" target="_blank" rel="noopener noreferrer">Wikipedia</a></quote></blockquote>


--></p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_webp1th.jpg" alt="PageSpeed Insights"></p>
<p>Googleが提供しているサイトスピード計測ツール「<a href="https://developers.google.com/speed/pagespeed/insights/?hl=ja" target="_blank" rel="noopener noreferrer">PageSpeed Insights</a>」では、JPEG XR、JPEG 2000などと同様に利用することを推奨されています。</p>
<p>Google神が勧めるのであれば、できる限り導入を検討した方が良いでしょう！</p>
<h3>WebPの対応ブラウザは？</h3>
<p>WebPは新規の画像形式ということもあり、対応していないブラウザやバージョンがあるのが現状です。</p>
<p>Google ChromeやFirefox、Operaなどでは対応していますが、<span class="fwb">利用ユーザーの多いSafariや、IEではまだ未対応</span>です（2019年9月現在）。</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_webp2th.jpg" alt="WebP image format"><br />
<span class="fs13 fcNote">Photo by：<a href="https://caniuse.com/#feat=webp" target="_blank" rel="noopener noreferrer">WebP image format</a></span></p>
<p>未対応のブラウザではWebPの画像は表示されませんので、「WebPの選択的レスポンス」つまり画像の出し分け設定をする必要があります。例えばWebPに対応しているChromeではWebPを、対応していないSafariでは従来の画像形式であるJPGやPNGを表示するなど。</p>
<p>一見難しそうですが、WordPressサイトの場合はプラグインの導入と「.htaccess」のファイルを少し追記するたけで設定できます。</p>
<h2>WebPの設定方法</h2>
<p>WebPの設定方法は、WordPressの場合そこまで難しくありません。一つ一つ確認していきましょう！</p>
<h3>1. EWWW Image Optimizerの導入</h3>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_14_EWWWImageOptimizer.png.jpg" alt="EWWW Image Optimizer"><br />
<span class="fs13 fcNote">photo by：<a href="https://ja.wordpress.org/plugins/ewww-image-optimizer/" target="_blank" rel="noopener noreferrer">wordpress公式サイト</a></span></p>
<p>まず画像圧縮・最適化のプラグイン「<a href="https://tekito-style.me/columns/wordpress-plugin-eww-imageoptimizer">EWWW Image Optimizer</a>」をインストール・有効化します。導入方法は基本的に他のWordPressプラグインと同じです。</p>
<p>このプラグインを活用すると、<span class="fwb">画像圧縮はもちろん、画像に保存されている不要なメタデータを削除したり、画像のWebP対応をする設定も可能です</span>。とっても便利ですね。</p>
<p>EWWW Image Optimizerの詳細な使い方については、以下の記事を参考にしてみてください。<br />
<div class="related_article typesimple"><a class="related_article__link no-icon" href="https://tekito-style.me/columns/wordpress-plugin-eww-imageoptimizer"><figure class="eyecatch of-cover thum"><img loading="lazy" decoding="async" width="485" height="287" src="https://tekito-style.me/wp-content/uploads/2019/09/th_0_EWWWImageOptimizer-485x287.png" class="archives-eyecatch-image attachment-oc-post-thum wp-post-image" alt="" srcset="https://tekito-style.me/wp-content/uploads/2019/09/th_0_EWWWImageOptimizer-485x287.png 485w, https://tekito-style.me/wp-content/uploads/2019/09/th_0_EWWWImageOptimizer-300x178.png 300w, https://tekito-style.me/wp-content/uploads/2019/09/th_0_EWWWImageOptimizer-768x454.png 768w, https://tekito-style.me/wp-content/uploads/2019/09/th_0_EWWWImageOptimizer.png 1014w" sizes="(max-width: 485px) 45vw, 485px" /></figure><div class="related_article__meta archives_post__meta inbox"><div class="related_article__ttl ttl"><span class="labeltext">関連記事</span>画像圧縮・最適化プラグインEWWW Image Optimizerの使い方・設定方法まとめ</div><time class="time__date gf undo">2020.04.20</time></div></a></div>
<h3>2. EWWW Image Optimizerで設定</h3>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_webp3.jpg" alt="EWWW Image Optimizer"></p>
<p>EWWW Image Optimizerを有効化したら、「WebP」タブを開きます。</p>
<div class="supplement boader">
[JPG, PNG から WebP]
</div>
<p>にチェックし、「変更を保存」をクリック。</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_webp4.jpg" alt="EWWW Image Optimizer"></p>
<p>するとコードが表示されるので、これを「.htaccess」ファイルに追記します。</p>
<p>この時点では画像のWebP対応が完了していないので、画面右下に赤枠で「PNG」を表示されています。WebP対応が完了すると、これが緑の枠で「WebP」表記に変更される感じです。</p>
<h3>3. 「.htaccess」ファイルへ追記</h3>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_webp5.jpg" alt="wordpressの.htaccessファイル"></p>
<p>サーバー内の「.htaccess」ファイルを、FTPソフトなどを使い開きます。</p>
<p>対象となるWordPressサイトの下記ディレクトリまで移動します。</p>
<div class="supplement boader">
/home/◯◯/www/wp<br />
</div>
<p>.htaccessファイルを見つけたら、ダウンロードします。</p>
<p>先頭に「.（ピリオド）」がつくのはUNIX系OSで不可視ファイルを意味するので、場合によってはダウンロードしてもファイルを確認できない場合があります。その場合は下記のキーを打つと、隠しファイルを表示することができます。</p>
<div class="cbox intitle is-style-blue_box type_normal"><div class="box_title"><span class="span__box_title">不可視ファイルの表示方法</span></div><div class="cboxcomment">
「command」＋「shift」＋「.」（MAC）<br />
</div></div>
<p>ちなみにWikipediaでは.htaccessファイルを下記で定義しています。</p>
<blockquote><p>
	.htaccess（ドットエイチティーアクセス）とは、Apacheを用いたWebサーバにおいて、ディレクトリ単位で設置及び設定を行える設定ファイルである。<br />
<cite><a href="https://ja.wikipedia.org/wiki/.htaccess" target="_blank" rel="noopener noreferrer">wikipedia</a></cite></p></blockquote>
<p>BASIC認証やリダイレクトの設定など、簡単に言えば<span class="fwb">Webサーバの動作を制御する設定ファイル</span>って感じですかね。記述をミスるとサイトが表示されなくなったりするので、あまり触れたくないファイルではあります……。</p>
<pre><code>&lt;ifmodule mod_rewrite.c=""&gt;
RewriteEngine On
RewriteCond %{HTTP_ACCEPT} image/webp
RewriteCond %{REQUEST_FILENAME} (.*)\.(jpe?g|png)$
RewriteCond %{REQUEST_FILENAME}\.webp -f
RewriteCond %{QUERY_STRING} !type=original
RewriteRule (.+)\.(jpe?g|png)$ %{REQUEST_FILENAME}.webp [T=image/webp,E=accept:1,L]
&lt;/ifmodule&gt;
&lt;ifmodule mod_headers.c=""&gt;
Header append Vary Accept env=REDIRECT_accept
&lt;/ifmodule&gt;
AddType image/webp .webp</code></pre>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_webp6.jpg" alt="wordpressの.htaccessファイル"></p>
<p>ファイルの先頭などに先程のコードを記載し、完了したらFTPでサーバー上にアップし上書きします。</p>
<p>こちらのコードの改良版については色々サンプルがあるので、「WebPの選択的レスポンス」について色々調べてみると良いかもです。上記のコードでも問題なく動作はしますので、今回はこのまま進めます。</p>
<h3>4. EWWW Image OptimizerでWebP化</h3>
<p>EWWW Image Optimizerを有効化し、「.htaccess」ファイルへの追記が完了すれば、これからアップロードされる画像については全て自動的にWebPへ最適化されます。</p>
<p>しかし注意点としては、<span class="fwb">設定前にアップロードした画像については自動的にはWebPへ最適化されません</span>。ですので手動で最適化する必要があります。といってもほぼワンクリックで完了です！</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_webp7.jpg" alt="EWWW Image Optimizer"></p>
<p>WordPressの管理画面から、メディア ＞ 一括最適化へ進めます。</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_webp8.jpg" alt="EWWW Image Optimizer"></p>
<p>「再最適化を強制」を選択し、「最適化されていない画像をスキャンする」をクリック。</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_webp9.jpg" alt="EWWW Image Optimizer"></p>
<p>続いて「最適化を開始」をクリック。</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_webp10.jpg" alt="EWWW Image Optimizer"></p>
<p>最適化が開始されていきます。これでこれまでアップロードされた画像を含めてWebp化してくれます！</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_webp11-1.jpg" alt="EWWW Image Optimizer"></p>
<p>最適化完了後、先程確認したEWWW Image Optimizerの設定画面の「WebP」タブを確認すると、画面右下に「WEBP」の表示を確認できます。</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_webp11-3.jpg" alt="EWWW Image Optimizer"></p>
<p>写真一覧でもWebP対応がされていることを確認できます。</p>
<p>これで無事画像のWebP化は完了です！！</p>
<h2>WebPの反映を確認する方法</h2>
<p>WebP対応が実際に動作しているのか実際に確認してみましょう。Google Chromeの検証ツールで確認可能です。</p>
<p>WebP対応したWordPressサイトを開き、デベロッパーツールを開きます。</p>
<div class="supplement boader">
表示 ＞ 開発/管理　＞ デベロッパー ツール<br />
</div>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_webp12.jpg" alt="デベロッパーツールでのWebP対応確認"></p>
<div class="supplement boader">
メニューのNetwork ＞ img<br />
</div>
<p>を選択します。</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_webp13.jpg" alt="デベロッパーツールでのWebP対応確認"></p>
<p>Typeの項目を確認し、「webp」の表示が確認できればWebP化できています。</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_webp15.jpg" alt="デベロッパーツールでのWebP対応確認"></p>
<p>PageSpeed Insightsでも、「次世代フォーマットでの画像配信」の項目が合格できています！！</p>
<p><span class="fwb">また実際にsafariやIEなどWebP対応していないブラウザでは、JPGやPNGなどのフォーマットで画像が表示されているのか（画像形式の出し分けができているのか）必ず実機で確認しておきましょう！</span></p>
<h2>画像データはWebPで軽量化すべし！</h2>
<p>ここまでWordPressサイトにおける、画像のWebP対応方法ついて紹介してきました。</p>
<p>サイトスピードを下げる主要因である画像データは、今回紹介したWebP対応するなどできる限り軽量化していきましょう。プラグインを活用すれば導入ハードルは低いですよ。</p>
<p>今回紹介したプラグイン「EWWW Image Optimizer」の使い方については、以下の記事も参考にしてみてくださいね。<br />
<div class="related_article typesimple"><a class="related_article__link no-icon" href="https://tekito-style.me/columns/wordpress-plugin-eww-imageoptimizer"><figure class="eyecatch of-cover thum"><img loading="lazy" decoding="async" width="485" height="287" src="https://tekito-style.me/wp-content/uploads/2019/09/th_0_EWWWImageOptimizer-485x287.png" class="archives-eyecatch-image attachment-oc-post-thum wp-post-image" alt="" srcset="https://tekito-style.me/wp-content/uploads/2019/09/th_0_EWWWImageOptimizer-485x287.png 485w, https://tekito-style.me/wp-content/uploads/2019/09/th_0_EWWWImageOptimizer-300x178.png 300w, https://tekito-style.me/wp-content/uploads/2019/09/th_0_EWWWImageOptimizer-768x454.png 768w, https://tekito-style.me/wp-content/uploads/2019/09/th_0_EWWWImageOptimizer.png 1014w" sizes="(max-width: 485px) 45vw, 485px" /></figure><div class="related_article__meta archives_post__meta inbox"><div class="related_article__ttl ttl"><span class="labeltext">関連記事</span>画像圧縮・最適化プラグインEWWW Image Optimizerの使い方・設定方法まとめ</div><time class="time__date gf undo">2020.04.20</time></div></a></div>
<p>またサイトスピード改善で実施した施策とスコアの検証結果については、下記の記事で全てまとめていくので、よかったら施策の参考にしてみてください。<br />
<div class="related_article typesimple"><a class="related_article__link no-icon" href="https://tekito-style.me/columns/wordpress-sitespeed"><figure class="eyecatch of-cover thum"><img loading="lazy" decoding="async" width="485" height="283" src="https://tekito-style.me/wp-content/uploads/2019/11/th_wordpress-speed-up_1130-485x283.jpg" class="archives-eyecatch-image attachment-oc-post-thum wp-post-image" alt="" srcset="https://tekito-style.me/wp-content/uploads/2019/11/th_wordpress-speed-up_1130-485x283.jpg 485w, https://tekito-style.me/wp-content/uploads/2019/11/th_wordpress-speed-up_1130-300x175.jpg 300w, https://tekito-style.me/wp-content/uploads/2019/11/th_wordpress-speed-up_1130-768x448.jpg 768w, https://tekito-style.me/wp-content/uploads/2019/11/th_wordpress-speed-up_1130-1024x597.jpg 1024w, https://tekito-style.me/wp-content/uploads/2019/11/th_wordpress-speed-up_1130.jpg 1200w" sizes="(max-width: 485px) 45vw, 485px" /></figure><div class="related_article__meta archives_post__meta inbox"><div class="related_article__ttl ttl"><span class="labeltext">関連記事</span>WordPressのサイトスピード改善で実施した12の施策とスコア結果まとめ</div><time class="time__date gf">2019.11.30</time></div></a></div>
<p>下記記事では、WordPressのおすすめプラグインを厳選して紹介しています ↓↓<br />
<div class="related_article typesimple"><a class="related_article__link no-icon" href="https://tekito-style.me/columns/wordpress-plugins-roundup"><figure class="eyecatch of-cover thum"><img loading="lazy" decoding="async" width="485" height="283" src="https://tekito-style.me/wp-content/uploads/2020/04/91-wp-plugin-top-485x283.png" class="archives-eyecatch-image attachment-oc-post-thum wp-post-image" alt="" srcset="https://tekito-style.me/wp-content/uploads/2020/04/91-wp-plugin-top-485x283.png 485w, https://tekito-style.me/wp-content/uploads/2020/04/91-wp-plugin-top-1536x896.png 1536w, https://tekito-style.me/wp-content/uploads/2020/04/91-wp-plugin-top-2048x1195.png 2048w, https://tekito-style.me/wp-content/uploads/2020/04/91-wp-plugin-top-300x175.png 300w, https://tekito-style.me/wp-content/uploads/2020/04/91-wp-plugin-top-768x448.png 768w, https://tekito-style.me/wp-content/uploads/2020/04/91-wp-plugin-top-1024x597.png 1024w" sizes="(max-width: 485px) 45vw, 485px" /></figure><div class="related_article__meta archives_post__meta inbox"><div class="related_article__ttl ttl"><span class="labeltext">関連記事</span>おすすめ＆定番のWordPressプラグイン12選まとめ</div><time class="time__date gf undo">2020.07.14</time></div></a></div>The post <a href="https://tekito-style.me/columns/wordpress-image-webp">WordPressサイトで画像をWebP（ウェッピー）対応し軽量化する方法</a> first appeared on <a href="https://tekito-style.me">Tekito style.me</a>.]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>画像圧縮・最適化プラグインEWWW Image Optimizerの使い方・設定方法まとめ</title>
		<link>https://tekito-style.me/columns/wordpress-plugin-eww-imageoptimizer</link>
		
		<dc:creator><![CDATA[やすのり]]></dc:creator>
		<pubDate>Mon, 16 Sep 2019 13:44:56 +0000</pubDate>
				<category><![CDATA[WordPress/ブログ運営]]></category>
		<category><![CDATA[Webマーケティング]]></category>
		<category><![CDATA[WordPress]]></category>
		<category><![CDATA[WordPressプラグイン]]></category>
		<category><![CDATA[サイトスピード改善]]></category>
		<guid isPermaLink="false">https://tekito-style.me/?p=3750</guid>

					<description><![CDATA[<p>EWWW Image Optimizerは、画像を軽量化・最適化できるWordPressプラグイン。自動で一括圧縮などもしてくれるので、画像が重くてサイトスピードが遅くなっている人におすすめしたいプラグインです。 今回は...</p>
The post <a href="https://tekito-style.me/columns/wordpress-plugin-eww-imageoptimizer">画像圧縮・最適化プラグインEWWW Image Optimizerの使い方・設定方法まとめ</a> first appeared on <a href="https://tekito-style.me">Tekito style.me</a>.]]></description>
										<content:encoded><![CDATA[<p><!--


<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_0_EWWWImageOptimizer.png" alt="EWWW Image Optimizer"></p>



--><div class="voice cf l "><figure class="icon"><img loading="lazy" decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_th_IMG_0018_circle.jpg" class="voice_icon__img" width="150" height="150"><figcaption class="name">やすのり</figcaption></figure><div class="voicecomment">こんにちは！「Tekito style」を運営している<a href="https://twitter.com/98nasi_nori" target="_blank" rel="noopener noreferrer">やすのり（@98nasi_nori）</a>です。普段は都内でWebディレクター/マーケターなどをしています。</div></div>
<p>EWWW Image Optimizerは、画像を軽量化・最適化できるWordPressプラグイン。自動で一括圧縮などもしてくれるので、画像が重くてサイトスピードが遅くなっている人におすすめしたいプラグインです。</p>
<p>今回は<span class="fwb">EWWW Image Optimizerの使い方や注意点などを解説</span>していくので、画像最適化のプラグインを探している方はぜひチェックしてみてください。</p>
<h2>EWWW Image Optimizerってどんなプラグイン？</h2>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_14_EWWWImageOptimizer.png.jpg" alt="EWWW Image Optimizer"><br />
<span class="fs13 fcNote">photo by：<a href="https://ja.wordpress.org/plugins/ewww-image-optimizer/" target="_blank" rel="noopener noreferrer">wordpress公式サイト</a></span></p>
<p>EWWW Image Optimizerは画像を最適化して表示速度を改善するプラグインです。<span class="fwb">画像圧縮はもちろん、画像に保存されている不要なメタデータを削除したり、最新の画像形式であるWebPへ対応する設定も可能です</span>。</p>
<p>細かい設定をすることも可能ですが、基本的に導入後のデフォルト設定で問題ないので簡単。すでにアップロード済みの画像を一括で圧縮でき、新規で登録される画像については自動で圧縮してくれます。</p>
<p>本ブログもサイトスピードがかなり遅かったのですが、一番ネックになっていそうだったのが画像データ周り。Webページの情報で重いのは画像データがメインですからね。サイト閲覧に負荷のかかる重いデータはどんどん軽くしていくべしです！</p>
<p><a href="https://ja.wordpress.org/plugins/ewww-image-optimizer/" target="_blank" rel="noopener noreferrer">EWWW Image Optimizer</a></p>
<h2>EWWW Image Optimizerの導入方法</h2>
<p>EWWW Image Optimizerの導入方法を見ていきましょう！基本的に他のWordPressプラグインと同じです。</p>
<h3>インストールと有効化</h3>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_1_EWWWImageOptimizer.jpg" alt="EWWW Image Optimizer"></p>
<p>管理画面のメニュー「プラグイン」&gt;「新規追加」から、「EWWW Image Optimizer」で検索。「いますぐインストール」をクリックし、有効化します。</p>
<h3>設定欄からインストールされてるか確認</h3>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_2_EWWWImageOptimizer.png.jpg" alt="EWWW Image Optimizer"></p>
<p>インストールを完了すると、管理画面の設定欄に「EWWW Image Optimizer」が追加されていればOKです。クリックして詳細を確認しましょう。</p>
<h2>EWWW Image Optimizerの使い方</h2>
<p>EWWW Image Optimizerの使い方を確認していきましょう。基本的にはデフォルト設定のまま使えます。</p>
<h3>1. 設定方法</h3>
<p>まずは画像圧縮・最適化に関わる項目の設定をする必要があります。</p>
<h4>basicタブ</h4>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_4_EWWWImageOptimizer.png.jpg" alt="EWWW Image Optimizer"></p>
<p>basicタブでは画像最適化の基本設定を行うことができます。</p>
<p>まず「Remove Metadata」の項目をチェックします。写真にはレンズ焦点距離や露光量、撮影日時・場所などのメタデータが保存されているのですが、そうした余分なデータを削除することができます。<span class="fwb">画像を軽くする観点でも、個人情報を守る意味でも設定しておくことをおすすめします</span>。</p>
<p>他の項目は基本デフォルトのままでOK！各画像の最適化レベルも「Pixel Perfect」で問題ないです。バックアップ元の設定は有料版のみ設定可能みたいです。</p>
<h4>convertタブ</h4>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_5_EWWWImageOptimizer.png.jpg" alt="EWWW Image Optimizer"></p>
<p>convertタブでは画像の形式を変換するときの設定ができます。画像形式を変換する必要は基本的にないので、特にいじる必要のないです。</p>
<p>ですが「コンバージョンリンクを非表示」の項目だけチェックしておきましょう。画像形式の変換を意図的あるいは間違ってできないようにする設定です。画像を複数人で管理する時にチェックしておくと安心です。</p>
<p>他の項目は基本デフォルトのままでOKです。</p>
<h4>WebPタブ</h4>
<p><span class="fwb">WebP（ウェッピー）は、Googleが提供する最新の静止画フォーマット</span>。既存の画像形式と比較して、約2〜3割サイズを小さくすることが可能です。</p>
<p>WebPタブでは画像をJPGやPNGから、WebPへ変換する設定ができます。WebPはChrome以外のブラウザでは現状対応していないので、設定する場合は色々と調整する必要があります。</p>
<p><a href="https://caniuse.com/#feat=webp" target="_blank" rel="noopener noreferrer">WebPのブラウザごとの対応状況</a></p>
<p>特に設定する予定のない方は、デフォルトのまま放置でOKです。画像のWebP対応については下記の記事で別途解説しています↓<br />
<div class="related_article typesimple"><a class="related_article__link no-icon" href="https://tekito-style.me/columns/wordpress-image-webp"><figure class="eyecatch of-cover thum"><img loading="lazy" decoding="async" width="485" height="283" src="https://tekito-style.me/wp-content/uploads/2019/09/th_th_webp-too-485x283.jpg" class="archives-eyecatch-image attachment-oc-post-thum wp-post-image" alt="" srcset="https://tekito-style.me/wp-content/uploads/2019/09/th_th_webp-too-485x283.jpg 485w, https://tekito-style.me/wp-content/uploads/2019/09/th_th_webp-too-300x175.jpg 300w, https://tekito-style.me/wp-content/uploads/2019/09/th_th_webp-too-768x448.jpg 768w, https://tekito-style.me/wp-content/uploads/2019/09/th_th_webp-too-1024x597.jpg 1024w, https://tekito-style.me/wp-content/uploads/2019/09/th_th_webp-too.jpg 1200w" sizes="(max-width: 485px) 45vw, 485px" /></figure><div class="related_article__meta archives_post__meta inbox"><div class="related_article__ttl ttl"><span class="labeltext">関連記事</span>WordPressサイトで画像をWebP（ウェッピー）対応し軽量化する方法</div><time class="time__date gf undo">2020.04.20</time></div></a></div>
<h3>2. 既に投稿済みの画像を一括圧縮する方法</h3>
<p>これからアップロードされる画像に関しては、上記で設定した方法で圧縮されますが、すでにアップロード済みの画像には反映されません。そのため<span class="fwb">既存の画像は別途圧縮する必要があります</span>。</p>
<p>そこで便利な機能が「一括最適化」機能。既存の画像をまとめて一括で圧縮することが可能です。</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_6_EWWWImageOptimizer.png" alt="EWWW Image Optimizer"></p>
<p>管理画面の左メニュー「メディア」欄から「一括最適化」をクリックします。</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_7_EWWWImageOptimizer.png.jpg" alt="EWWW Image Optimizer"></p>
<p>「最適化されていない画像をスキャンする」を選択。</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_8_EWWWImageOptimizer.png.jpg" alt="EWWW Image Optimizer"></p>
<p>なんと8,000枚以上画像の圧縮ができそうとのこと。「最適化を開始」をクリックします。</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_9_EWWWImageOptimizer.png.jpg" alt="EWWW Image Optimizer"></p>
<p>どの画像が最適化されているのか、進行状況を確認できます。</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_10_EWWWImageOptimizer.png.jpg" alt="EWWW Image Optimizer"></p>
<p>トータルで所要時間3時間もかかりそう。しばし待ちましたが、実際は1時間半くらいで全ての画像のリサイズが完了しました。</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_11_EWWWImageOptimizer.png" alt="EWWW Image Optimizer"></p>
<p>最適化済みの項目数を確認すると、全ての最適化が完了したことが分かります。</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_12_EWWWImageOptimizer.png.jpg" alt="EWWW Image Optimizer"></p>
<p>どれくらい画像が最適化されたのか、結果も確認することができます。<span class="fwb">画像の25%が圧縮</span>されたようです。<br />
<div class="supplement boader">
<ul>
<li>圧縮：25%</li>
<li>リサイズ：20%</li>
<li>削除結果：54.76 MB</li>
</ul>
</div>
<p>これまで画像は細めに1枚1枚リサイズと圧縮をしてからアップロードしていたのですが、それでもまだまだ圧縮できたようですね……。なるほど。</p>
<h3>3. 新規投稿する画像を圧縮・最適化する方法</h3>
<p><span class="fwb">EWWW Image Optimizerを有効化していれば、今後新規で追加した画像は自動で最適化されます</span>。ですので今後は一括圧縮することも不要な感じです！</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_13_EWWWImageOptimizer.png.jpg" alt="EWWW Image Optimizer"></p>
<p>アップロードされた画像がどれくらい圧縮されているのかは、管理画面の「メディア」&gt;「ライブラリ」の画像一覧から確認することができます。</p>
<h2>画像圧縮・最適化ならEWWW Image Optimizer</h2>
<p>WordPressサイトの画像の圧縮・最適化なら、EWWW Image Optimizerはおすすめなプラグインです。簡単に設定・導入でき、自動で画像圧縮をしてくれるとても便利なプラグインです。</p>
<p>画像が重くてサイトスピードが低い方などは、ぜひ試してみてはいかがでしょうか？</p>
<p>追加で対策しておきたい、画像のWebP対応については下記記事で解説しています↓<br />
<div class="related_article typesimple"><a class="related_article__link no-icon" href="https://tekito-style.me/columns/wordpress-image-webp"><figure class="eyecatch of-cover thum"><img loading="lazy" decoding="async" width="485" height="283" src="https://tekito-style.me/wp-content/uploads/2019/09/th_th_webp-too-485x283.jpg" class="archives-eyecatch-image attachment-oc-post-thum wp-post-image" alt="" srcset="https://tekito-style.me/wp-content/uploads/2019/09/th_th_webp-too-485x283.jpg 485w, https://tekito-style.me/wp-content/uploads/2019/09/th_th_webp-too-300x175.jpg 300w, https://tekito-style.me/wp-content/uploads/2019/09/th_th_webp-too-768x448.jpg 768w, https://tekito-style.me/wp-content/uploads/2019/09/th_th_webp-too-1024x597.jpg 1024w, https://tekito-style.me/wp-content/uploads/2019/09/th_th_webp-too.jpg 1200w" sizes="(max-width: 485px) 45vw, 485px" /></figure><div class="related_article__meta archives_post__meta inbox"><div class="related_article__ttl ttl"><span class="labeltext">関連記事</span>WordPressサイトで画像をWebP（ウェッピー）対応し軽量化する方法</div><time class="time__date gf undo">2020.04.20</time></div></a></div>
<p>またサイトスピード改善で実施した施策とスコアの検証結果については、下記の記事で全てまとめていくので、よかったら施策の参考にしてみてください。<br />
<div class="related_article typesimple"><a class="related_article__link no-icon" href="https://tekito-style.me/columns/wordpress-sitespeed"><figure class="eyecatch of-cover thum"><img loading="lazy" decoding="async" width="485" height="283" src="https://tekito-style.me/wp-content/uploads/2019/11/th_wordpress-speed-up_1130-485x283.jpg" class="archives-eyecatch-image attachment-oc-post-thum wp-post-image" alt="" srcset="https://tekito-style.me/wp-content/uploads/2019/11/th_wordpress-speed-up_1130-485x283.jpg 485w, https://tekito-style.me/wp-content/uploads/2019/11/th_wordpress-speed-up_1130-300x175.jpg 300w, https://tekito-style.me/wp-content/uploads/2019/11/th_wordpress-speed-up_1130-768x448.jpg 768w, https://tekito-style.me/wp-content/uploads/2019/11/th_wordpress-speed-up_1130-1024x597.jpg 1024w, https://tekito-style.me/wp-content/uploads/2019/11/th_wordpress-speed-up_1130.jpg 1200w" sizes="(max-width: 485px) 45vw, 485px" /></figure><div class="related_article__meta archives_post__meta inbox"><div class="related_article__ttl ttl"><span class="labeltext">関連記事</span>WordPressのサイトスピード改善で実施した12の施策とスコア結果まとめ</div><time class="time__date gf">2019.11.30</time></div></a></div>
<p>下記記事では、WordPressのおすすめプラグインを厳選して紹介しています ↓↓<br />
<div class="related_article typesimple"><a class="related_article__link no-icon" href="https://tekito-style.me/columns/wordpress-plugins-roundup"><figure class="eyecatch of-cover thum"><img loading="lazy" decoding="async" width="485" height="283" src="https://tekito-style.me/wp-content/uploads/2020/04/91-wp-plugin-top-485x283.png" class="archives-eyecatch-image attachment-oc-post-thum wp-post-image" alt="" srcset="https://tekito-style.me/wp-content/uploads/2020/04/91-wp-plugin-top-485x283.png 485w, https://tekito-style.me/wp-content/uploads/2020/04/91-wp-plugin-top-1536x896.png 1536w, https://tekito-style.me/wp-content/uploads/2020/04/91-wp-plugin-top-2048x1195.png 2048w, https://tekito-style.me/wp-content/uploads/2020/04/91-wp-plugin-top-300x175.png 300w, https://tekito-style.me/wp-content/uploads/2020/04/91-wp-plugin-top-768x448.png 768w, https://tekito-style.me/wp-content/uploads/2020/04/91-wp-plugin-top-1024x597.png 1024w" sizes="(max-width: 485px) 45vw, 485px" /></figure><div class="related_article__meta archives_post__meta inbox"><div class="related_article__ttl ttl"><span class="labeltext">関連記事</span>おすすめ＆定番のWordPressプラグイン12選まとめ</div><time class="time__date gf undo">2020.07.14</time></div></a></div>The post <a href="https://tekito-style.me/columns/wordpress-plugin-eww-imageoptimizer">画像圧縮・最適化プラグインEWWW Image Optimizerの使い方・設定方法まとめ</a> first appeared on <a href="https://tekito-style.me">Tekito style.me</a>.]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>リビジョン削除のWordPressプラグインOptimize Database after Deleting Revisionsの使い方まとめ</title>
		<link>https://tekito-style.me/columns/wordpress-plugin-optimizerevisions</link>
		
		<dc:creator><![CDATA[やすのり]]></dc:creator>
		<pubDate>Mon, 16 Sep 2019 09:13:42 +0000</pubDate>
				<category><![CDATA[Webマーケティング]]></category>
		<category><![CDATA[WordPress/ブログ運営]]></category>
		<category><![CDATA[WordPress]]></category>
		<category><![CDATA[WordPressプラグイン]]></category>
		<category><![CDATA[サイトスピード改善]]></category>
		<guid isPermaLink="false">https://tekito-style.me/?p=3727</guid>

					<description><![CDATA[<p>Optimize Database after Deleting Revisionsは、リビジョンデータの削除・管理でおすすめなWordPressプラグイン。 リビジョンとはWordPressに溜まった、記事の下書きや更...</p>
The post <a href="https://tekito-style.me/columns/wordpress-plugin-optimizerevisions">リビジョン削除のWordPressプラグインOptimize Database after Deleting Revisionsの使い方まとめ</a> first appeared on <a href="https://tekito-style.me">Tekito style.me</a>.]]></description>
										<content:encoded><![CDATA[<p><!--


<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_1topOptimizeDatabase.jpg" alt="Optimize Database after Deleting Revisions"></p>



--><div class="voice cf l "><figure class="icon"><img loading="lazy" decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_th_IMG_0018_circle.jpg" class="voice_icon__img" width="150" height="150"><figcaption class="name">やすのり</figcaption></figure><div class="voicecomment">こんにちは！「Tekito style」を運営している<a href="https://twitter.com/98nasi_nori" target="_blank" rel="noopener noreferrer">やすのり（@98nasi_nori）</a>です。普段は都内でWebディレクター/マーケターなどをしています。</div></div>
<p>Optimize Database after Deleting Revisionsは、リビジョンデータの削除・管理でおすすめなWordPressプラグイン。</p>
<p>リビジョンとはWordPressに溜まった、記事の下書きや更新前データのこと。余分なリビジョンが溜まるとデータベースを圧迫し、サイトスピードにも悪影響を与えます。</p>
<p>今回は<span class="fwb">Optimize Database after Deleting Revisionsの使い方や注意点などを解説</span>していくので、ぜひチェックしてみてください。</p>
<h2>Optimize Database after Deleting Revisionsってどんなプラグイン？</h2>
<p><span class="fwb">Optimize Database after Deleting Revisionsは、WordPressに溜まったリビジョンデータを削除したり、保存件数を指定することができるプラグイン</span>。他にもゴミ箱のデータや、使っていないタグを削除してくれたりと何かと便利なツールです。</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_4optimizerevisions.jpg" alt="WordPressのリビジョン"></p>
<p>リビジョンは投稿の編集画面を開いていると自動的に内容を保存をしてくれる、WordPressでデフォルトで搭載されている機能です。</p>
<p>「記事を更新したけどある特定時点での内容に戻したい！」という時に役立ちます。</p>
<p>しかし下書きデータが溜まるとその分データベースが重くなってしまうので、リビジョンは定期的にメンテナンスをするべきです。<span class="fwb">余分なリビジョンを減らせばその分データベースが軽くなり、サイトスピードの改善、ひいてはSEO面でもメリットがあります</span>。</p>
<p>記事の下書きデータって、実際そんな何個もいらないですよね？？リビジョンを削除しないと知らないうちにどんどん増えていくので、効率的に管理すべきでしょう。</p>
<p><a href="https://ja.wordpress.org/plugins/rvg-optimize-database/" target="_blank" rel="noopener noreferrer">Optimize Database after Deleting Revisions</a></p>
<h3>プラグインを使わずリビジョンを削除する方法もあるけど……</h3>
<p>プラグインを使わなくても「<span class="fwb">wp-config.php</span>」ファイルに特定の記述をすることで、リビジョンの保存件数や自動更新の間隔を任意の値に設定することが可能です。</p>
<p>しかしその場合は設定以前のリビジョンデータは残ったままとなってしまいます（設定した時点以降のリビジョンデータには反映される）。</p>
<p>リビジョンデータを削除するとなると、直接データベースを操作する必要があります。ですのでデータベースをいじるのに抵抗がある場合や、<span class="fwb">すでにある程度のコンテンツ数がある場合はプラグインを使って削除する方が安全で簡単な方法ではあります</span>。</p>
<p>ワードプレス導入後すぐに設定するなら、wp-config.phpファイルを編集する方が余計にプラグインを使わないのでおすすめです。<br />
参考：<a href="https://www.itti.jp/web-design/wp-revision-cont/" target="_blank" rel="noopener noreferrer">ワードプレスのリビジョンの停止や制限、自動保存の停止や設定の方法</a></p>
<h2>Optimize Database after Deleting Revisionsの導入方法</h2>
<p>Optimize Database after Deleting Revisionsの導入方法を見ていきましょう！基本的に他のWordPressプラグインと同じです。</p>
<h3>インストールと有効化</h3>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_5optimizerevisions.png" alt="Optimize Database after Deleting Revisions"></p>
<p>管理画面のメニュー「プラグイン」&gt;「新規追加」から、「Optimize Database after Deleting Revisions」で検索。「いますぐインストール」をクリックし、有効化します。</p>
<h3>ツール欄からインストールされてるか確認</h3>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_6optimizerevisions.png" alt="Optimize Database after Deleting Revisions"></p>
<p>インストールを完了すると、管理画面左メニューのツール欄に「Optimize Database」が追加されていればOKです。クリックして詳細を確認しましょう。</p>
<h2>Optimize Database after Deleting Revisionsの使い方</h2>
<p>Optimize Database after Deleting Revisionsの使い方はかなりシンプルです。確認していきましょう。</p>
<h3>1. 必ずバックアップを！</h3>
<p>Optimize Database after Deleting Revisionsを使う前に、必ず事前にデータのバックアップを取っておきましょう！もし不具合が起きても前の環境に戻すことが可能です。</p>
<p>バックアップには下記のプラグインがおすすめです ↓<br />
<div class="related_article typesimple"><a class="related_article__link no-icon" href="https://tekito-style.me/columns/wordpress-plugin-updraftplus"><figure class="eyecatch of-cover thum"><img loading="lazy" decoding="async" width="485" height="303" src="https://tekito-style.me/wp-content/uploads/2019/09/th_1topUpdraftPlus2-485x303.jpg" class="archives-eyecatch-image attachment-oc-post-thum wp-post-image" alt="" srcset="https://tekito-style.me/wp-content/uploads/2019/09/th_1topUpdraftPlus2-485x303.jpg 485w, https://tekito-style.me/wp-content/uploads/2019/09/th_1topUpdraftPlus2-300x188.jpg 300w, https://tekito-style.me/wp-content/uploads/2019/09/th_1topUpdraftPlus2-768x480.jpg 768w, https://tekito-style.me/wp-content/uploads/2019/09/th_1topUpdraftPlus2-1024x640.jpg 1024w, https://tekito-style.me/wp-content/uploads/2019/09/th_1topUpdraftPlus2.jpg 1200w" sizes="(max-width: 485px) 45vw, 485px" /></figure><div class="related_article__meta archives_post__meta inbox"><div class="related_article__ttl ttl"><span class="labeltext">関連記事</span>バックアップ専用プラグインUpdraftPlusの使い方・設定方法まとめ</div><time class="time__date gf undo">2022.02.22</time></div></a></div>
<h3>2. リビジョンの削除設定</h3>
<p>「Delete revisions for the following (custom) post type(s):」とあるので、チェックした項目のリビジョンが削除されます。</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_7optimizerevisions.jpg" alt="Optimize Database after Deleting Revisions"></p>
<p>実際に設定した項目については、上記を参考にしてみてください。</p>
<table>
<tbody>
<tr>
<th>post</th>
<td>記事ページのリビジョン削除</td>
</tr>
<tr>
<th>page</th>
<td>固定ページのリビジョン削除</td>
</tr>
<tr>
<th>user_request</th>
<td>カスタム投稿のリビジョン削除</td>
</tr>
<tr>
<th>wp_block</th>
<td>ブロックのリビジョン削除</td>
</tr>
<tr>
<th>amn_mi-lite</th>
<td>カスタム投稿（プラグイン：MonsterInsights）のリビジョン削除</td>
</tr>
<tr>
<th>post_lp</th>
<td>カスタム投稿（テーマ：：Stork生成のランディングページ）のリビジョン削除</td>
</tr>
<tr>
<th>Delete revisions older than</th>
<td>指定期間前のリビジョン削除</td>
</tr>
<tr>
<th>Maximum number of &#8211; most recent &#8211; revisions<br />
to keep per post / page</th>
<td>保存するリビジョンの最大数を指定</td>
</tr>
</tbody>
</table>
<p>保存するリビジョンの最大数もお好みで設定できますが、僕は5に設定しています。リビジョンを全く使わない人は0（つまりリビジョンを保存しない）も設定できますが、<span class="fwb">万が一の時に備えて数回程度は設定しておくといいかと思います</span>。</p>
<p>また特定のテーマやプラグインを使っていると、それらの項目が生成するカスタム投稿タイプも表示されるようです。ですので上記項目はWordPressの動作環境によっても異なるかなと思います。</p>
<h3>3. 不要データの削除とその他の設定</h3>
<p>チェックすると不要なデータを削除することができます。僕は下記の項目にチェックを入れています。</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_8optimizerevisions.jpg" alt="Optimize Database after Deleting Revisions"></p>
<table>
<tbody>
<tr>
<th>Delete trashed items</th>
<td>ゴミ箱のデータ削除</td>
</tr>
<tr>
<th>Delete spammed items</th>
<td>スパム項目の削除</td>
</tr>
<tr>
<th>Delete unused tags</th>
<td>未使用タグの削除</td>
</tr>
<tr>
<th>Clear oEmbed cache</th>
<td>oEmbedキャッシュの削除</td>
</tr>
<tr>
<th>Keep a log</th>
<td>ログを保持する</td>
</tr>
<tr>
<th>Scheduler</th>
<td>最適化を自動実行する間隔</td>
</tr>
<tr>
<th>Time</th>
<td>自動実行のタイミング</td>
</tr>
<tr>
<th>Show &#8216;1-click&#8217; link in Admin Bar*</th>
<td>管理画面（へッダー）に項目追加</td>
</tr>
<tr>
<th>Show an icon in the Admin Menu*</th>
<td>管理画面（サイドバー）にアイコン追加</td>
</tr>
</tbody>
</table>
<p>必要な項目にチェックを入れ、「Save Settings」ボタンをクリックし設定を保存。「Go to Optimizer」をクリックし実行するだけです！</p>
<h3>4. データベース最適化の実行</h3>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_9_2optimizerevisions.jpg" alt="Optimize Database after Deleting Revisions"></p>
<p>するとこちらの画面に移るので、詳細な結果を確認したい場合は「Optimize（detail）」、簡単に結果のサマリーが欲しい場合は「Optimize（Summary）」をクリックします。</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_10optimizerevisions.jpg" alt="Optimize Database after Deleting Revisions"></p>
<p>最適化された結果が表示されました。57記事のリビジョンが削除されたようです。</p>
<div class="supplement boader">
【Cleaning Database】<br />
REVISIONS deleted: 57<br />
TRASHED ITEMS deleted: 1<br />
No SPAMMED ITEMS found to delete<br />
OEMBED CACHE ITEMS deleted: 7</p>
<p>【Savings】<br />
BEFORE optimization	34.141 MB<br />
AFTER optimization	34.141 MB<br />
SAVINGS THIS TIME	0 KB<br />
TOTAL SAVINGS SINCE THE FIRST RUN	0 KB<br />
</div>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_11optimizerevisions.jpg" alt="Optimize Database after Deleting Revisions"></p>
<p>ログも合わせて確認すると、57記事で<span class="fwb">トータル645ものリビジョンを削除してくれた</span>みたいです。結構溜まっていたようなのでスッキリ。</p>
<p>データベースのサイズはあまり変わっていない？ようです。645ものリビジョンを削除したのに謎ですが……。<br />
とにかく不要なデータは削除してもらえたようです。</p>
<h2>リビジョン削除にはプラグインを有効活用しよう！</h2>
<p>WordPressのリビジョンや不要データを削除しデータベースを最適化したいのであれば、Optimize Database after Deleting Revisionsは簡単に設定・実行できるおすすめなプラグインです。</p>
<p>ぜひWordPressでサイトを運営している方は参考にいただけると幸いです。<br />
最後までお読みいただきありがとうございます！</p>
<p>またサイトスピード改善で実施した施策とスコアの検証結果については、下記の記事で全てまとめていくので、よかったら施策の参考にしてみてください。<br />
<div class="related_article typesimple"><a class="related_article__link no-icon" href="https://tekito-style.me/columns/wordpress-sitespeed"><figure class="eyecatch of-cover thum"><img loading="lazy" decoding="async" width="485" height="283" src="https://tekito-style.me/wp-content/uploads/2019/11/th_wordpress-speed-up_1130-485x283.jpg" class="archives-eyecatch-image attachment-oc-post-thum wp-post-image" alt="" srcset="https://tekito-style.me/wp-content/uploads/2019/11/th_wordpress-speed-up_1130-485x283.jpg 485w, https://tekito-style.me/wp-content/uploads/2019/11/th_wordpress-speed-up_1130-300x175.jpg 300w, https://tekito-style.me/wp-content/uploads/2019/11/th_wordpress-speed-up_1130-768x448.jpg 768w, https://tekito-style.me/wp-content/uploads/2019/11/th_wordpress-speed-up_1130-1024x597.jpg 1024w, https://tekito-style.me/wp-content/uploads/2019/11/th_wordpress-speed-up_1130.jpg 1200w" sizes="(max-width: 485px) 45vw, 485px" /></figure><div class="related_article__meta archives_post__meta inbox"><div class="related_article__ttl ttl"><span class="labeltext">関連記事</span>WordPressのサイトスピード改善で実施した12の施策とスコア結果まとめ</div><time class="time__date gf">2019.11.30</time></div></a></div>
<p>下記記事では、WordPressのおすすめプラグインを厳選して紹介しています ↓↓<br />
<div class="related_article typesimple"><a class="related_article__link no-icon" href="https://tekito-style.me/columns/wordpress-plugins-roundup"><figure class="eyecatch of-cover thum"><img loading="lazy" decoding="async" width="485" height="283" src="https://tekito-style.me/wp-content/uploads/2020/04/91-wp-plugin-top-485x283.png" class="archives-eyecatch-image attachment-oc-post-thum wp-post-image" alt="" srcset="https://tekito-style.me/wp-content/uploads/2020/04/91-wp-plugin-top-485x283.png 485w, https://tekito-style.me/wp-content/uploads/2020/04/91-wp-plugin-top-1536x896.png 1536w, https://tekito-style.me/wp-content/uploads/2020/04/91-wp-plugin-top-2048x1195.png 2048w, https://tekito-style.me/wp-content/uploads/2020/04/91-wp-plugin-top-300x175.png 300w, https://tekito-style.me/wp-content/uploads/2020/04/91-wp-plugin-top-768x448.png 768w, https://tekito-style.me/wp-content/uploads/2020/04/91-wp-plugin-top-1024x597.png 1024w" sizes="(max-width: 485px) 45vw, 485px" /></figure><div class="related_article__meta archives_post__meta inbox"><div class="related_article__ttl ttl"><span class="labeltext">関連記事</span>おすすめ＆定番のWordPressプラグイン12選まとめ</div><time class="time__date gf undo">2020.07.14</time></div></a></div>The post <a href="https://tekito-style.me/columns/wordpress-plugin-optimizerevisions">リビジョン削除のWordPressプラグインOptimize Database after Deleting Revisionsの使い方まとめ</a> first appeared on <a href="https://tekito-style.me">Tekito style.me</a>.]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>プラグイン不要！ブラウザキャッシュを設定しWordPressのサイトスピードを改善する方法</title>
		<link>https://tekito-style.me/columns/sitespeed-browser-cashe</link>
		
		<dc:creator><![CDATA[やすのり]]></dc:creator>
		<pubDate>Sun, 15 Sep 2019 13:20:19 +0000</pubDate>
				<category><![CDATA[Webマーケティング]]></category>
		<category><![CDATA[WordPress/ブログ運営]]></category>
		<category><![CDATA[WordPress]]></category>
		<category><![CDATA[サイトスピード改善]]></category>
		<guid isPermaLink="false">https://tekito-style.me/?p=3703</guid>

					<description><![CDATA[<p>サイトスピードの改善施策として、ブラウザ（Google Chromeやsafariなど）のキャッシュを活用する方法があります。 ユーザーがページを閲覧した際に、HTMLやCSS、画像などのリソースをブラウザが一時保存（ブ...</p>
The post <a href="https://tekito-style.me/columns/sitespeed-browser-cashe">プラグイン不要！ブラウザキャッシュを設定しWordPressのサイトスピードを改善する方法</a> first appeared on <a href="https://tekito-style.me">Tekito style.me</a>.]]></description>
										<content:encoded><![CDATA[<p><!--


<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/top_browser-cashe.png" alt="ブラウザキャッシュ"></p>



--><div class="voice cf l "><figure class="icon"><img loading="lazy" decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_th_IMG_0018_circle.jpg" class="voice_icon__img" width="150" height="150"><figcaption class="name">やすのり</figcaption></figure><div class="voicecomment">こんにちは！「Tekito style」を運営している<a href="https://twitter.com/98nasi_nori" target="_blank" rel="noopener noreferrer">やすのり（@98nasi_nori）</a>です。普段は都内でWebディレクター/マーケターなどをしています。</div></div>
サイトスピードの改善施策として、ブラウザ（Google Chromeやsafariなど）のキャッシュを活用する方法があります。</p>
<p>ユーザーがページを閲覧した際に、HTMLやCSS、画像などのリソースをブラウザが一時保存（ブラウザキャッシュ）することで、同じページを再訪問した時に表示スピードを上げることができます。</p>
<p>WordPressプラグインを使わなくても、「.htaccess」というファイルを編集するだけでOKなので、そこまで難しくありません。</p>
<p>ということで今回は、<span class="fwb">.htaccessファイルを調整し、WordPressサイトのブラウザキャッシュを有効にする設定方法をご紹介していきます</span>。</p>
<h2>ブラウザキャッシュとは？</h2>
<p>ブラウザキャッシュとは、ブラウザがユーザーの閲覧したページデータを一時的に保存してくれる機能です。HTMLやCSSなどでのデザイン情報やJavaScriptファイル、画像データなどが含まれます。</p>
<p>キャッシュはブラウザ経由で閲覧しているデバイスに保存されるため、同じページを訪問する度にサーバーから毎回同じデータを取得する必要がなくなります。<span class="fwb">サーバーとやりとりする回数が減るので、その分ページを表示するスピードを改善できる</span>のです。</p>
<p>逆にページを表示するために必要なデータが多いほど、サーバーにリクエストする回数が多いほど表示スピードが下がります。</p>
<p>特に画像を良く使うサイトやページはサイトスピードが遅くなりがちなので、キャッシュを上手く活用し表示速度を上げることはユーザビリティ改善にとって重要です。ユーザビリティの高いサイトは、もちろんSEO面でもプラスに効きます。</p>
<p>ちなみにブラウザキャッシュの保存容量はブラウザごとに決まっていて、容量を超えると古いデータから削除されていきます。</p>
<p>またどのリソースをどれくらいの期間保存させるかはサイト側が設定できます。ですのでリソースによって保存期間が異なるケースもあります（HTMLデータは1週間、画像は1ヶ月保存されるなど）。</p>
<h2>WordPressでブラウザキャッシュを設定する方法</h2>
<p>ブラウザキャッシュを有効化するためには、サーバー内にある「.htaccess」というファイルを編集する必要があります。</p>
<p>WordPressサイトの場合プラグインを使うことで対応することも可能ですが、極力プラグインは使わない方がバグが発生する可能性を減らせますし、サイトが重くならないです。</p>
<p>ということで手順を確認していきましょう。</p>
<h3>1. FTPで.htaccessをダウンロード</h3>
<p>FTPソフトなどを使って、対象となるWordPressサイトの下記ディレクトリまで移動します。</p>
<div class="supplement boader">
/home/◯◯/www/wp<br />
</div>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_1_browser-cashe.jpg" alt="FTPソフト"></p>
<p>.htaccessファイルを見つけたら、ダウンロードします。</p>
<p>先頭に「.（ピリオド）」がつくのはUNIX系OSで不可視ファイルを意味するので、場合によってはダウンロードしてもファイルを確認できない場合があります。その場合は下記のキーを打つと、隠しファイルを表示することができます。</p>
<div class="cbox intitle is-style-blue_box type_normal"><div class="box_title"><span class="span__box_title">不可視ファイルの表示方法</span></div><div class="cboxcomment">
「command」＋「shift」＋「.」（MAC）<br />
</div></div>
<p>ちなみにWikipediaでは.htaccessファイルを下記で定義しています。</p>
<blockquote><p>
	.htaccess（ドットエイチティーアクセス）とは、Apacheを用いたWebサーバにおいて、ディレクトリ単位で設置及び設定を行える設定ファイルである。<br />
<cite><a href="https://ja.wikipedia.org/wiki/.htaccess" target="_blank" rel="noopener noreferrer">wikipedia</a></cite></p></blockquote>
<p>BASIC認証やリダイレクトの設定など、簡単に言えば<span class="fwb">Webサーバの動作を制御する設定ファイル</span>って感じですかね。記述をミスるとサイトが表示されなくなったりするので、あまり触れたくないファイルではあります……。</p>
<h3>2. コードを修正する</h3>
<p>.htaccessファイルに下記のコードを加え、FTPでサーバー上にアップし上書きします。</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_2_browser-cashe.jpg" alt=".htaccessファイル"></p>
<pre><code>&lt;ifmodule mod_expires.c=""&gt;
ExpiresActive On
ExpiresByType text/html "access plus 3 days"
ExpiresByType text/css "access plus 3 days"
ExpiresByType text/javascript "access plus 1 weeks"
ExpiresByType application/javascript "access plus 1 weeks"
ExpiresByType application/x-javascript "access plus 1 weeks"
ExpiresByType image/jpg "access plus 2 weeks"
ExpiresByType image/jpeg "access plus 2 weeks"
ExpiresByType image/png "access plus 2 weeks"
ExpiresByType image/gif "access plus 2 weeks"
ExpiresByType image/x-icon "access plus 1 month"
ExpiresByType image/svg+xml "access plus 2 weeks"
&lt;/ifmodule&gt;</code></pre>
<p>できる限りファイルの上部に記述しましょう。</p>
<p>またimage/jpgやimage/pngなど、画像キャッシュの場合は対応する種類ごとに設定する必要があります。x-iconはファビコン、text/cssはCSSファイル、text/javascriptはJSファイルですね。</p>
<p>「access plus 2 weeks」はアクセス後2週間キャッシュを保持するという意味です。他にも</p>
<div class="supplement boader">
hours（時間）<br />
days（日）<br />
weeks（週）<br />
month（月）<br />
years（年）<br />
</div>
<p>などの記述が可能です。</p>
<p>僕はサイトのデザインを割と頻繁に微調整するので、キャッシュの保持期間はCSSは3日だけにしています。逆にファビコンや記事中の画像などはほとんど変更しないので、1ヶ月保存する設定にしています。</p>
<p>ブラウザキャッシュを有効にした場合のデメリットの1つは、例えばサイトのデザインを更新した時にユーザー側のブラウザにキャッシュが残り、最新のデザインが反映されないケースがあることです。</p>
<p><span class="fwb">ですのでキャッシュの保存期間は、どれくらいの頻度でリソースを更新する予定があるかに合わせ調整しましょう</span>。</p>
<h2>更新が反映されない時の対処法</h2>
<p>もし自分のブラウザにキャッシュが残り、サイトのデザインなどを変更したのになかなか反映されない時は「スーパーリロード」をしてみましょう。</p>
<p>スーパーリロードすることで、キャッシュの有無に関わらず最新の状態をブラウザに反映させることができます。それでもキャッシュが残る場合は、ブラウザからキャッシュ自体を削除しましょう。</p>
<div class="cbox intitle is-style-blue_box type_normal"><div class="box_title"><span class="span__box_title">スーパーリロードのショートカット</span></div><div class="cboxcomment">
MAC：「⌘」+「shift」+「R」<br />
Windows：「ctrl」+「F5」<br />
</div></div>
<h2>ブラウザキャッシュでWordPressサイトを高速に！</h2>
<p>いかがでしたか？.htaccessファイルを調整することで、ブラウザキャッシュは簡単に設定することが可能です。また.htaccessを更新した後は、サイトの表示や挙動に異常が出ていないか必ず確認しておきましょう！</p>
<p>少しでもWordPressのサイトスピード改善につながれば幸いです。</p>
<p>合わせて知っておきたいサーバーキャッシュについて ↓↓<br />
<div class="related_article typesimple"><a class="related_article__link no-icon" href="https://tekito-style.me/columns/wordpress-plugin-fastest-cache"><figure class="eyecatch of-cover thum"><img loading="lazy" decoding="async" width="485" height="283" src="https://tekito-style.me/wp-content/uploads/2019/10/th_WPFastestCache_top_1021-485x283.jpg" class="archives-eyecatch-image attachment-oc-post-thum wp-post-image" alt="" srcset="https://tekito-style.me/wp-content/uploads/2019/10/th_WPFastestCache_top_1021-485x283.jpg 485w, https://tekito-style.me/wp-content/uploads/2019/10/th_WPFastestCache_top_1021-300x175.jpg 300w, https://tekito-style.me/wp-content/uploads/2019/10/th_WPFastestCache_top_1021-768x448.jpg 768w, https://tekito-style.me/wp-content/uploads/2019/10/th_WPFastestCache_top_1021-1024x597.jpg 1024w, https://tekito-style.me/wp-content/uploads/2019/10/th_WPFastestCache_top_1021.jpg 1200w" sizes="(max-width: 485px) 45vw, 485px" /></figure><div class="related_article__meta archives_post__meta inbox"><div class="related_article__ttl ttl"><span class="labeltext">関連記事</span>WP Fastest Cacheの使い方・設定方法【キャッシュ改善のおすすめプラグイン】</div><time class="time__date gf undo">2020.04.20</time></div></a></div>
<p>またサイトスピード改善で実施した施策とスコアの検証結果については、下記の記事で全てまとめていくので、よかったら施策の参考にしてみてください。<br />
<div class="related_article typesimple"><a class="related_article__link no-icon" href="https://tekito-style.me/columns/wordpress-sitespeed"><figure class="eyecatch of-cover thum"><img loading="lazy" decoding="async" width="485" height="283" src="https://tekito-style.me/wp-content/uploads/2019/11/th_wordpress-speed-up_1130-485x283.jpg" class="archives-eyecatch-image attachment-oc-post-thum wp-post-image" alt="" srcset="https://tekito-style.me/wp-content/uploads/2019/11/th_wordpress-speed-up_1130-485x283.jpg 485w, https://tekito-style.me/wp-content/uploads/2019/11/th_wordpress-speed-up_1130-300x175.jpg 300w, https://tekito-style.me/wp-content/uploads/2019/11/th_wordpress-speed-up_1130-768x448.jpg 768w, https://tekito-style.me/wp-content/uploads/2019/11/th_wordpress-speed-up_1130-1024x597.jpg 1024w, https://tekito-style.me/wp-content/uploads/2019/11/th_wordpress-speed-up_1130.jpg 1200w" sizes="(max-width: 485px) 45vw, 485px" /></figure><div class="related_article__meta archives_post__meta inbox"><div class="related_article__ttl ttl"><span class="labeltext">関連記事</span>WordPressのサイトスピード改善で実施した12の施策とスコア結果まとめ</div><time class="time__date gf">2019.11.30</time></div></a></div>The post <a href="https://tekito-style.me/columns/sitespeed-browser-cashe">プラグイン不要！ブラウザキャッシュを設定しWordPressのサイトスピードを改善する方法</a> first appeared on <a href="https://tekito-style.me">Tekito style.me</a>.]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>Scripts-To-Footerの使い方・設定方法まとめ！JSをフッターに一括移動できるプラグイン</title>
		<link>https://tekito-style.me/columns/wordpress-plugin-scriptstofooter</link>
		
		<dc:creator><![CDATA[やすのり]]></dc:creator>
		<pubDate>Sun, 15 Sep 2019 08:35:54 +0000</pubDate>
				<category><![CDATA[Webマーケティング]]></category>
		<category><![CDATA[WordPress/ブログ運営]]></category>
		<category><![CDATA[WordPress]]></category>
		<category><![CDATA[WordPressプラグイン]]></category>
		<category><![CDATA[サイトスピード改善]]></category>
		<guid isPermaLink="false">https://tekito-style.me/?p=3690</guid>

					<description><![CDATA[<p>WordPressのサイトスピード対策として、JavascriptやCSSなどのリソースの読み込みを遅らせる方法があります。 そこで便利なプラグインが「Scripts-To-Footer」。JavaScriptをフッター...</p>
The post <a href="https://tekito-style.me/columns/wordpress-plugin-scriptstofooter">Scripts-To-Footerの使い方・設定方法まとめ！JSをフッターに一括移動できるプラグイン</a> first appeared on <a href="https://tekito-style.me">Tekito style.me</a>.]]></description>
										<content:encoded><![CDATA[<p><!--


<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_0_top.jpg" alt="Scripts-To-Footer"></p>



--><div class="voice cf l "><figure class="icon"><img loading="lazy" decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_th_IMG_0018_circle.jpg" class="voice_icon__img" width="150" height="150"><figcaption class="name">やすのり</figcaption></figure><div class="voicecomment">こんにちは！「Tekito style」を運営している<a href="https://twitter.com/98nasi_nori" target="_blank" rel="noopener noreferrer">やすのり（@98nasi_nori）</a>です。普段は都内でWebディレクター/マーケターなどをしています。</div></div>
<p>WordPressのサイトスピード対策として、JavascriptやCSSなどのリソースの読み込みを遅らせる方法があります。</p>
<p><span class="fwb">そこで便利なプラグインが「Scripts-To-Footer」。JavaScriptをフッターで読み込ませることで、サイトの表示速度を改善できます</span>。</p>
<p>今回はScripts-To-Footerの使い方や注意点などを解説していくので、WordPressのサイトスピード改善を検討している方はチェックしてみてください。</p>
<h2>Scripts-To-Footerってどんなプラグイン？</h2>
<p>Scripts-To-Footerは名前の通り、Javascriptを一括でサイトフッター（bodyタグの直前）で読み込ませることができるWordPressプラグイン。レンダリングで重要度の高いソースコードを先に表示し、クリティカルでないJSを後で読み込むことでサイトの表示速度を改善できます。</p>
<p>レンダリングをブロックしているリソースの記述箇所を、<span class="fwb">プラグインを導入するだけでコードを修正せずにまとめて簡単に移動できます</span>。</p>
<p>最近のワードプレステーマはデフォルトで上記対策をしていることも多いですが、プラグインや計測ツールなど色々導入していると、知らず知らずのうちにレンダリングの妨げになっていることも多いです。</p>
<p>利用するプラグインが多くなればそれだけサイトが重くなるので、できればScripts-To-Footerを利用せずに自分でソースコードを調整した方が良い感じではあります。ですが自分でソースコードをいじれない方や、プラグインを入れ変えるたびに管理するのが手間な方にとってはとても便利なプラグインでしょう。</p>
<p><a href="https://ja.wordpress.org/plugins/scripts-to-footerphp/" target="_blank" rel="noopener noreferrer">Scripts To Footer</a></p>
<h3>実際にPageSpeed Insightで確認してみると</h3>
<p>Googleが提供するサイトスピード計測ができる「<a href="https://developers.google.com/speed/pagespeed/insights/?hl=ja" target="_blank" rel="noopener noreferrer">PageSpeed Insight</a>」で確認してみると、下記の改善アドバイスを確認できました。</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_5_Scripts-To-Footer.jpg" alt="PageSpeed Insight"></p>
<blockquote><p>
「レンダリングを妨げるリソースの除外」<br />
ページの初回ペイントをリソースが阻害しています。クリティカルな JS や CSS はインラインで配信し、それ以外の JS やスタイルはすべて遅らせることをご検討ください。<br />
<cite><a href="https://developers.google.com/speed/pagespeed/insights/?hl=ja" target="_blank" rel="noopener noreferrer">PageSpeed Insight</a></cite></p></blockquote>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_6_Scripts-To-Footer.jpg" alt="PageSpeed Insight"></p>
<p>指摘されたのは上記のようなファイルですね。JSを使っているプラグインや計測ツールの他に、子テーマのCSS、font-awesomeなど。</p>
<p>Googleさんから重要度の低いリソースは後で読み込め、と言われればそれに従うまでです……！</p>
<h2>Scripts-To-Footerの導入方法</h2>
<p>Scripts-To-Footerの導入方法を見ていきましょう！基本的に他のWordPressプラグインと同じです。</p>
<h3>インストールと有効化</h3>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_7_Scripts-To-Footer.jpg" alt="Scripts-To-Footer"></p>
<p>管理画面のメニュー「プラグイン」&gt;「新規追加」から、「Scripts-To-Footer」で検索。「いますぐインストール」をクリックし、有効化します。</p>
<h3>設定欄からインストールされてるか確認</h3>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_8_Scripts-To-Footer.png" alt="Scripts-To-Footer"></p>
<p>インストールを完了すると、管理画面の設定欄に「Scripts-To-Footer」が追加されていればOKです。クリックして詳細を確認しましょう。</p>
<h2>Scripts-To-Footerの使い方</h2>
<p>Scripts-To-Footerの使い方はかなりシンプルです。<span class="fwb">基本的にプラグインを導入したら、すぐにスクリプトをフッターに移動してくれます</span>。</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_9_Scripts-To-Footer.jpg" alt="Scripts-To-Footer"></p>
<p>「Select which templates should not have scripts moved to the footer:」とあるので、JSをフッターに移動したくないページの場合はチェックを入れる感じですね。</p>
<div class="supplement boader">
<ul>
<li>Blog Page（記事ページ）</li>
<li>Search Results（検索結果ページ）</li>
<li>404 pages（404ページ）</li>
<li>Post Type Archives（記事アーカイブページ）</li>
<li>Taxonomy Archives（分類ページ ex タグ、カテゴリ）</li>
<li>Author Archives（投稿者アーカイブページ）</li>
<li>Other Archive Pages（その他アーカイブ）</li>
</ul>
</div>
<p>ただし基本的にチェックをつけず、全てのページを対象にして良いかと思います。</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_9-2_Scripts-To-Footer.jpg" alt="Scripts-To-Footer"></p>
<p>ちなみに記事投稿・編集ページから、個別の記事ごとにプラグインのオン・オフも指定することが可能です。あまり利用機会はなさそうですが、固定ページをゴリゴリJSでいじる場合などでは使えるかも。</p>
<h3>Scripts-To-Footerの注意事項</h3>
<p><span class="fwb">Scripts-To-FooterでJSを全てフッターに移動すると、予期しないエラーが起こるケースがあります</span>。Javascriptをゴリゴリ使っているページで、JSの読み込みを遅らせるとサイトの挙動に影響でそうなページがあれば、上記した除外項目に個別にチェックをつけましょう！</p>
<p>またWordPressはjQueryが使われているプラグインやテーマが多いので、全てのスクリプトを後回しで読み込むとプログラムが動作しなくなることもあります。アニメーションが動かなくなったり、スクロールができなくなったり、ボタンが機能しなくなったり。</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_10_Scripts-To-Footer.jpg" alt="Scripts-To-Footer"></p>
<p>そうしたエラーが発生した場合は「<span class="fwb">Keep jQuery in the Header</span>」にチェックをすれば、jQueryのみを移動対象から除外することができます。</p>
<p>実際に現在僕が使っているWordPressテーマ「stork」と相性が悪いようで、調べたところデザインが崩れたり、コンテンツが非表示になるブロガーさんもいたようです。</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_11_Scripts-To-Footer.jpg" alt="Tekito Style"></p>
<p>僕もプラグインを起動したら、TOPページの記事スライダーが消失しました（汗）。ですが「Keep jQuery in the Header」にチェックをつけたら正常に動作しましたよ！</p>
<p><span class="fwb">Scripts-To-Footerを導入した後は、サイトのどこかでエラーが発生していないか、動作に問題ないかを必ずチェックしておくことをおすすめします</span>。</p>
<h2>Scripts-To-Footerを有効活用しよう！</h2>
<p>サイトスピード対策で、さくっとJSをフッターに移動してレンダリング速度を上げたいのであれば、Scripts-To-Footerは簡単に導入できておすすめなプラグインです。</p>
<p>ただし導入後はサイト上でエラーが起きていないか、必ず確認しましょう。できればデータのバックアップも取っておくとより安心です。</p>
<p>バックアップについては下記のプラグイン「UpdraftPlus」がおすすめです↓<br />
<div class="related_article typesimple"><a class="related_article__link no-icon" href="https://tekito-style.me/columns/wordpress-plugin-updraftplus"><figure class="eyecatch of-cover thum"><img loading="lazy" decoding="async" width="485" height="303" src="https://tekito-style.me/wp-content/uploads/2019/09/th_1topUpdraftPlus2-485x303.jpg" class="archives-eyecatch-image attachment-oc-post-thum wp-post-image" alt="" srcset="https://tekito-style.me/wp-content/uploads/2019/09/th_1topUpdraftPlus2-485x303.jpg 485w, https://tekito-style.me/wp-content/uploads/2019/09/th_1topUpdraftPlus2-300x188.jpg 300w, https://tekito-style.me/wp-content/uploads/2019/09/th_1topUpdraftPlus2-768x480.jpg 768w, https://tekito-style.me/wp-content/uploads/2019/09/th_1topUpdraftPlus2-1024x640.jpg 1024w, https://tekito-style.me/wp-content/uploads/2019/09/th_1topUpdraftPlus2.jpg 1200w" sizes="(max-width: 485px) 45vw, 485px" /></figure><div class="related_article__meta archives_post__meta inbox"><div class="related_article__ttl ttl"><span class="labeltext">関連記事</span>バックアップ専用プラグインUpdraftPlusの使い方・設定方法まとめ</div><time class="time__date gf undo">2022.02.22</time></div></a></div>
<p>またサイトスピード改善で実施した施策とスコアの検証結果については、下記の記事で全てまとめていくので、よかったら施策の参考にしてみてください。<br />
<div class="related_article typesimple"><a class="related_article__link no-icon" href="https://tekito-style.me/columns/wordpress-sitespeed"><figure class="eyecatch of-cover thum"><img loading="lazy" decoding="async" width="485" height="283" src="https://tekito-style.me/wp-content/uploads/2019/11/th_wordpress-speed-up_1130-485x283.jpg" class="archives-eyecatch-image attachment-oc-post-thum wp-post-image" alt="" srcset="https://tekito-style.me/wp-content/uploads/2019/11/th_wordpress-speed-up_1130-485x283.jpg 485w, https://tekito-style.me/wp-content/uploads/2019/11/th_wordpress-speed-up_1130-300x175.jpg 300w, https://tekito-style.me/wp-content/uploads/2019/11/th_wordpress-speed-up_1130-768x448.jpg 768w, https://tekito-style.me/wp-content/uploads/2019/11/th_wordpress-speed-up_1130-1024x597.jpg 1024w, https://tekito-style.me/wp-content/uploads/2019/11/th_wordpress-speed-up_1130.jpg 1200w" sizes="(max-width: 485px) 45vw, 485px" /></figure><div class="related_article__meta archives_post__meta inbox"><div class="related_article__ttl ttl"><span class="labeltext">関連記事</span>WordPressのサイトスピード改善で実施した12の施策とスコア結果まとめ</div><time class="time__date gf">2019.11.30</time></div></a></div>
<p>下記記事では、WordPressのおすすめプラグインを厳選して紹介しています ↓↓<br />
<div class="related_article typesimple"><a class="related_article__link no-icon" href="https://tekito-style.me/columns/wordpress-plugins-roundup"><figure class="eyecatch of-cover thum"><img loading="lazy" decoding="async" width="485" height="283" src="https://tekito-style.me/wp-content/uploads/2020/04/91-wp-plugin-top-485x283.png" class="archives-eyecatch-image attachment-oc-post-thum wp-post-image" alt="" srcset="https://tekito-style.me/wp-content/uploads/2020/04/91-wp-plugin-top-485x283.png 485w, https://tekito-style.me/wp-content/uploads/2020/04/91-wp-plugin-top-1536x896.png 1536w, https://tekito-style.me/wp-content/uploads/2020/04/91-wp-plugin-top-2048x1195.png 2048w, https://tekito-style.me/wp-content/uploads/2020/04/91-wp-plugin-top-300x175.png 300w, https://tekito-style.me/wp-content/uploads/2020/04/91-wp-plugin-top-768x448.png 768w, https://tekito-style.me/wp-content/uploads/2020/04/91-wp-plugin-top-1024x597.png 1024w" sizes="(max-width: 485px) 45vw, 485px" /></figure><div class="related_article__meta archives_post__meta inbox"><div class="related_article__ttl ttl"><span class="labeltext">関連記事</span>おすすめ＆定番のWordPressプラグイン12選まとめ</div><time class="time__date gf undo">2020.07.14</time></div></a></div>The post <a href="https://tekito-style.me/columns/wordpress-plugin-scriptstofooter">Scripts-To-Footerの使い方・設定方法まとめ！JSをフッターに一括移動できるプラグイン</a> first appeared on <a href="https://tekito-style.me">Tekito style.me</a>.]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>PHP Compatibility Checkerの使い方・設定方法まとめ！PHPバージョンUPで必須のプラグイン</title>
		<link>https://tekito-style.me/columns/plugin-php-compatibilitychecker</link>
		
		<dc:creator><![CDATA[やすのり]]></dc:creator>
		<pubDate>Sat, 14 Sep 2019 10:54:30 +0000</pubDate>
				<category><![CDATA[Webマーケティング]]></category>
		<category><![CDATA[WordPress/ブログ運営]]></category>
		<category><![CDATA[WordPress]]></category>
		<category><![CDATA[WordPressプラグイン]]></category>
		<category><![CDATA[サイトスピード改善]]></category>
		<guid isPermaLink="false">https://tekito-style.me/?p=3666</guid>

					<description><![CDATA[<p>WordPressでサイト運営しているのであれば、対応しているPHPのバージョンはできる限り最新のものにしておきたいところ。ですがPHPのバージョンを変更するとなると、場合によっては不具合が起きるケースもあるので慎重に作...</p>
The post <a href="https://tekito-style.me/columns/plugin-php-compatibilitychecker">PHP Compatibility Checkerの使い方・設定方法まとめ！PHPバージョンUPで必須のプラグイン</a> first appeared on <a href="https://tekito-style.me">Tekito style.me</a>.]]></description>
										<content:encoded><![CDATA[<p><!--


<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_0top3_PHP-Compatibility-Checker.jpg" alt="PHP Compatibility Checker"></p>



--><div class="voice cf l "><figure class="icon"><img loading="lazy" decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_th_IMG_0018_circle.jpg" class="voice_icon__img" width="150" height="150"><figcaption class="name">やすのり</figcaption></figure><div class="voicecomment">こんにちは！「Tekito style」を運営している<a href="https://twitter.com/98nasi_nori" target="_blank" rel="noopener noreferrer">やすのり（@98nasi_nori）</a>です。普段は都内でWebディレクター/マーケターなどをしています。</div></div>
<p>WordPressでサイト運営しているのであれば、対応しているPHPのバージョンはできる限り最新のものにしておきたいところ。ですがPHPのバージョンを変更するとなると、場合によっては不具合が起きるケースもあるので慎重に作業を進めるべきです。</p>
<p><span class="fwb">そこで便利なプラグインが「PHP Compatibility Checker」。サイトで導入しているテーマやプラグインが、特定のPHPのバージョンに対応しているのか否かを判定してくれます</span>。</p>
<p>今回はPHP Compatibility Checkerの使い方や注意点などを解説していくので、5から7系へ移行予定の方などPHPのバージョンアップデートを検討している方はぜひチェックしてみてください。</p>
<h2>「PHP Compatibility Checker」ってどんなプラグイン？</h2>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_th_1top_PHP-Compatibility-Checker-772x250.jpg" alt="PHP Compatibility Checker"><br />
<span class="fs13 fcNote">photo by：<a href="https://wpengine.com/solution-center/php-compatibility-checker/" target="_blank" rel="noopener noreferrer">WP Engine公式サイト</a></span></p>
<p>PHP Compatibility Checkerは、<a href="https://wpengine.com/" target="_blank" rel="noopener noreferrer">WP Engine</a>が提供するWordPressプラグイン。WordPressサイトで導入しているテーマやプラグインが、切り替えたいPHPのバージョンに対応しているかチェックしてくれます。</p>
<p>現状のコードで問題がありそうな箇所を発見し、何が課題なのか簡単に内容をレポートしてくれます。</p>
<p>そもそもWordPressサイトはPHPという言語で動作しており、PHPのバージョンを最新のものにしておくとサイトスピードが改善できたり、セキュリティ面でもより安全に運営することができます。最新バージョンであるPHP7は、PHP5に比べ2倍以上のパフォーマンス改善を見込めるようです。</p>
<p>しかしもしPHPのバージョンを変更したくても、<span class="fwb">今使っているテーマやプラグインが変更する最新のPHPに対応していない場合、デザインが崩れたり挙動がおかしくなったり、最悪の場合サイトが正常に動作しなくなるケースもあります</span>。古いバージョンのPHPで記述されたプログラムの一部が、最新のバージョン環境で動かなくなることがあるためです。</p>
<p>そこでPHP Compatibility Checkerを使えばその課題を事前に特定し、トラブルを未然に防ぐことが可能です。もちろんサイトによって条件が異なるので、<span class="fwb">100%の安全を保証するものではありません</span>。ですがトラブルの芽を摘むためにも、できる限りの手は尽くしておくべきでしょう。</p>
<p><a href="https://ja.wordpress.org/plugins/php-compatibility-checker/PHP Compatibility Checker" target="_blank" rel="noopener noreferrer">PHP Compatibility Checker</a></p>
<h2>事前にサイトのPHPバージョンを確認する方法</h2>
<p>現時点でどのバージョンなのか把握できていない方は、事前に必ず確認しておきましょう。WordPressのPHPバージョン設定は、レンタルサーバー会社がサーバー側で管理しています。</p>
<p>各主要サーバーごとのバージョン確認方法は、下記公式サイトをご確認ください。</p>
<div class="supplement boader">
<ul>
<li><a href="https://help.sakura.ad.jp/hc/ja/articles/115000135681-PHP%E3%81%AE%E3%83%90%E3%83%BC%E3%82%B8%E3%83%A7%E3%83%B3%E5%A4%89%E6%9B%B4" target="_blank" rel="noopener noreferrer">さくらサーバーのPHPバージョン確認方法</a></li>
<li><a href="https://www.xserver.ne.jp/manual/man_program_php_ver.php" target="_blank" rel="noopener noreferrer">エックスサーバーのPHPバージョン確認方法</a></li>
<li><a href="https://lolipop.jp/manual/user/php-setting/" target="_blank" rel="noopener noreferrer">ロリポップのPHPバージョン確認方法</a></li>
<li><a href="https://help.mixhost.jp/hc/ja/articles/115003736351-PHP%E3%81%AE%E3%83%90%E3%83%BC%E3%82%B8%E3%83%A7%E3%83%B3%E3%82%92%E7%A2%BA%E8%AA%8D%E3%81%99%E3%82%8B%E6%96%B9%E6%B3%95" target="_blank" rel="noopener noreferrer">mixhostのPHPバージョン確認方法</a></li>
</ul>
</div>
<h3>実際にさくらサーバーで確認してみた</h3>
<p>僕は現状さくらサーバーを主に使っているので、実際にさくらサーバーのPHPバージョンを確認してみました。</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_11PHPCompatibility-Checker.jpg" alt="PHP Compatibility Checker"></p>
<p>まずコントロールパネルにアクセスし、サイドバーにある「PHPのバージョン選択」します。</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_12PHPCompatibility-Checker.png" alt="PHP Compatibility Checker"></p>
<p>確認していると、PHP 5.6.40 （CGI版）でした。これを最新のPHP 7.3へ変更します。CGIからパフォーマンスの高いモジュール版へ移行したいところですが…… その話はまた今度に。</p>
<h2>PHP Compatibility Checkerの導入方法</h2>
<p>PHP Compatibility Checkerの導入方法を見ていきましょう！基本的に他のWordPressプラグインと同じです。</p>
<h3>インストールと有効化</h3>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_2PHPCompatibility-Checker.jpg" alt="PHP Compatibility Checker"></p>
<p>管理画面のメニュー「プラグイン」&gt;「新規追加」から、「PHP Compatibility Checker」で検索。「いますぐインストール」をクリックし、有効化します。</p>
<h3>設定欄からインストールされてるか確認</h3>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_3PHPCompatibility-Checker.jpg" alt="PHP Compatibility Checker"></p>
<p>インストールを完了すると、管理画面のツール欄に「PHP Compatibility」が追加されていればOKです。クリックして詳細を確認しましょう。</p>
<h2>PHP Compatibility Checkerの使い方</h2>
<p>PHP Compatibility Checkerの使い方はかなりシンプルです。確認していきましょう。</p>
<h3>既存のプラグインやテーマの互換性を調べる</h3>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_4-2PHPCompatibility-Checker.jpg" alt="PHP Compatibility Checker"></p>
<p>現状WordPressで導入しているプラグインやテーマが、最新のPHPバージョンに対応しているのかを確認します。</p>
<p>まずPHPバージョン欄を、変更したい最新の「7.3」にチェックし、「有効化中のプラグインとテーマのみをスキャン」を選択します。</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_5PHPCompatibility-Checker.jpg" alt="PHP Compatibility Checker"></p>
<p><span class="fwb">スキャンには割と時間がかかります</span>。1プラグインにつき1〜2分ほど。僕は20分ほどかかりました。ですので有効化していないプラグインとテーマをチェックするのはやめておきましょう。</p>
<p><span class="fwb">「互換性あり」と表示されたものは問題ありません！</span> 最新のPHPバージョンに対応しています。</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_6PHPCompatibility-Checker.png" alt="PHP Compatibility Checker"></p>
<p>プラグインのSearch Regexのみ「警告」が出ました……。</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_10_2PHPCompatibility-Checker.jpg" alt="PHP Compatibility Checker"></p>
<p>警告された内容を確認すると以下のような内容でした。</p>
<div class="supplement boader">
&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;<br />
FOUND 0 ERRORS AND 1 WARNING AFFECTING 1 LINE<br />
&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;<br />
55 | WARNING | INI directive &#8216;safe_mode&#8217; is deprecated since PHP 5.3 and removed since PHP 5.4<br />
&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;<br />
</div>
<p>php.iniファイルの中の「safe_mode」の記述が、5.3のバージョンから非推奨になり、5.4から取り除かれた、ということらしいです。エラーメッセージを検索にかけると、同様の指摘を受けているケースが見られました。色々調べたところ変更しても時に大きな問題はなさそう（常時使っているプラグインでもない）だったので、今回はそのまま進めることに。</p>
<p>※PHPの公式サイト：<a href="https://www.php.net/manual/ja/features.safe-mode.php" target="_blank" rel="noopener noreferrer">セーフモード</a><br />
※参考事例：<a href="https://wordpress.org/support/topic/ini-directive-safe_mode-is-deprecated-since-php-5-3-and-removed-since-php-5-4/" target="_blank" rel="noopener noreferrer">INI directive ‘safe_mode’ is deprecated since PHP 5.3 and removed since PHP 5.4.</a></p>
<p>削除された関数が使われているプラグインの場合、最新のPHP環境で動作しなくなる可能性もありますので、エラー内容の意味や対処法が分からない場合はとにかくググりましょう！</p>
<h3>レポート内容のダウンロードも可能</h3>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_8PHPCompatibility-Checker.jpg" alt="PHP Compatibility Checker"></p>
<p>レポート内容は、テキストファイルで一括ダウンロードすることも可能です。チェックする項目が多い場合は使ってみてください。</p>
<h2>警告やエラーが出た時の対処法</h2>
<p>もし最新のPHPバージョンとの互換性について警告が出た場合は、主に下記の方法で対処します。</p>
<div class="supplement boader">
<ul>
<li>そのプラグインやテーマを最新のバージョンにUPする</li>
<li>そのプラグインやテーマを削除する</li>
<li>別の互換性のあるプラグインやテーマに切り替える</li>
<li>どうしても使いたいプラグインやテーマの場合、いったん保留にして最新のPHPに対応するのを待つ</li>
</ul>
</div>
<p>サイトで導入しているプラグインやテーマは、事前に最新のバージョンに更新しておきましょう。一度警告がでても、バージョンを更新すれば最新のPHPに対応しているケースも多いです。更新がもう数年されていないプラグインなどはそもそも使うのは控えたいところ……。</p>
<p>また警告がでているプラグインは、本当に必要なのか改めて精査しましょう。なくても問題なければ思い切って削除するか、他に同様の機能を備えた最新のPHPに対応しているプラグインに切り替えるのも選択肢です。</p>
<p>自分でプラグインやテーマのエラー箇所を修正する手段もありますが、開発の知見・スキルのある方以外は控えましょう。</p>
<h3>PHP Compatibility Checkerの注意事項</h3>
<p>PHP Compatibility CheckerのWordPress公式サイトでは、下記の注意事項を掲載しています。</p>
<blockquote><p>
このプラグインはできる限り多くの問題を正確に検出するよう作成していますが、100%確実な検出は非常に困難です。新しい PHP バージョンに移行する前に、総合テストの実施をお勧めします。<br />
<cite>引用元：<a href="https://ja.wordpress.org/plugins/php-compatibility-checker/" target="_blank" rel="noopener noreferrer">https://ja.wordpress.org/plugins/php-compatibility-checker/</a></cite></p></blockquote>
<blockquote><p>
このプラグインでは、下位互換で使用する未知のコード/パスを互換性無しと判定することがあります。誤判定の可能性があるプラグインは、プラグインのホワイトリストにまとめてあります。<br />
<cite>引用元：<a href="https://ja.wordpress.org/plugins/php-compatibility-checker/" target="_blank" rel="noopener noreferrer">https://ja.wordpress.org/plugins/php-compatibility-checker/</a></cite></p></blockquote>
<p>WordPressの動作環境はサイトによってそれぞれ異なります。PHP Compatibility Checkerといえども、さすがに<span class="fwb">100%の精度でエラーを検出することは難しい</span>ので、実行前に必ずデータのバックアップを取り、バージョンアップデートした後もエラーが発生していないかサイトを隈なくチェックすべきでしょう。</p>
<p>誤判定の可能性があるプラグインのホワイトリストも事前に目を通しておくことをおすすめします。<br />
<a href="https://github.com/wpengine/phpcompat/wiki/Results" target="_blank" rel="noopener noreferrer">https://github.com/wpengine/phpcompat/wiki/Results</a></p>
<h2>実際にさくらサーバーでPHPのバージョンアップをしてみた</h2>
<p>ということで、PHPのバージョンアップを実際にしてみました！</p>
<h3>必ずバックアップを！</h3>
<p><span class="fwb">バージョンアップの前に必ずデータのバックアップを取っておきましょう！</span>バックアップについては以下のプラグイン「UpdraftPlus」がおすすめです！<br />
<div class="related_article typesimple"><a class="related_article__link no-icon" href="https://tekito-style.me/columns/wordpress-plugin-updraftplus"><figure class="eyecatch of-cover thum"><img loading="lazy" decoding="async" width="485" height="303" src="https://tekito-style.me/wp-content/uploads/2019/09/th_1topUpdraftPlus2-485x303.jpg" class="archives-eyecatch-image attachment-oc-post-thum wp-post-image" alt="" srcset="https://tekito-style.me/wp-content/uploads/2019/09/th_1topUpdraftPlus2-485x303.jpg 485w, https://tekito-style.me/wp-content/uploads/2019/09/th_1topUpdraftPlus2-300x188.jpg 300w, https://tekito-style.me/wp-content/uploads/2019/09/th_1topUpdraftPlus2-768x480.jpg 768w, https://tekito-style.me/wp-content/uploads/2019/09/th_1topUpdraftPlus2-1024x640.jpg 1024w, https://tekito-style.me/wp-content/uploads/2019/09/th_1topUpdraftPlus2.jpg 1200w" sizes="(max-width: 485px) 45vw, 485px" /></figure><div class="related_article__meta archives_post__meta inbox"><div class="related_article__ttl ttl"><span class="labeltext">関連記事</span>バックアップ専用プラグインUpdraftPlusの使い方・設定方法まとめ</div><time class="time__date gf undo">2022.02.22</time></div></a></div>
<h3>サーバーの管理画面から切り替え</h3>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_12PHPCompatibility-Checker.png" alt="PHP Compatibility Checker"></p>
<p>さくらサーバーの管理画面へ移行し、バージョンを切り替えます。新しいバージョン欄をPHP 7.3でチェックし変更をクリックします。</p>
<p class="tac"><img decoding="async" src="https://tekito-style.me/wp-content/uploads/2019/09/th_13PHPCompatibility-Checker.png" alt="PHP Compatibility Checker"></p>
<p>すると、もうPHPが最新バージョンに切り替わってました！<span class="fwb">切り替え自体はかなり簡単でした</span>。もちろん使っているサーバーによって異なりますので、改めて下記公式サイトをご確認くださいませ。</p>
<div class="supplement boader">
<ul>
<li><a href="https://help.sakura.ad.jp/hc/ja/articles/115000135681-PHP%E3%81%AE%E3%83%90%E3%83%BC%E3%82%B8%E3%83%A7%E3%83%B3%E5%A4%89%E6%9B%B4" target="_blank" rel="noopener noreferrer">さくらサーバーのPHPバージョン変更方法</a></li>
<li><a href="https://www.xserver.ne.jp/manual/man_program_php_ver.php" target="_blank" rel="noopener noreferrer">エックスサーバーのPHPバージョン変更方法</a></li>
<li><a href="//lolipop.jp/manual/user/php-setting/" target="_blank" rel="noopener noreferrer">ロリポップのPHPバージョン変更方法</a></li>
<li><a href="https://help.mixhost.jp/hc/ja/articles/115003742152-PHP%E3%81%AE%E3%83%90%E3%83%BC%E3%82%B8%E3%83%A7%E3%83%B3%E5%A4%89%E6%9B%B4" target="_blank" rel="noopener noreferrer">mixhostのPHPバージョン変更方法</a></li>
</ul>
</div>
<p>切り替え後はエラーが起きていないか、サイト全体を必ず確認しておきましょう！</p>
<h2>PHP Compatibility Checkerを有効活用しよう！</h2>
<p>PHPのバージョンを切り替えることで処理速度の改善が期待でき、セキュリティも高まりますので、まだ5系を使っている方はできる限り最新の7系に切り替えましょう！</p>
<p>PHP Compatibility Checkerを活用すれば、事前にPHPの互換性を確認でき問題が発生するのを回避できます。ただしエラーの特定が漏れる場合もあるので、必ず事前にバックアップを取っておくことをおすすめします。</p>
<p>また今回はサイトスピード改善の一環としてPHPのバージョン更新をしたのですが、スピード改善で実施した施策とスコアの検証結果については、下記の記事で全てまとめていきます。よかったら施策の参考にしてみてください。それでは！<br />
<div class="related_article typesimple"><a class="related_article__link no-icon" href="https://tekito-style.me/columns/wordpress-sitespeed"><figure class="eyecatch of-cover thum"><img loading="lazy" decoding="async" width="485" height="283" src="https://tekito-style.me/wp-content/uploads/2019/11/th_wordpress-speed-up_1130-485x283.jpg" class="archives-eyecatch-image attachment-oc-post-thum wp-post-image" alt="" srcset="https://tekito-style.me/wp-content/uploads/2019/11/th_wordpress-speed-up_1130-485x283.jpg 485w, https://tekito-style.me/wp-content/uploads/2019/11/th_wordpress-speed-up_1130-300x175.jpg 300w, https://tekito-style.me/wp-content/uploads/2019/11/th_wordpress-speed-up_1130-768x448.jpg 768w, https://tekito-style.me/wp-content/uploads/2019/11/th_wordpress-speed-up_1130-1024x597.jpg 1024w, https://tekito-style.me/wp-content/uploads/2019/11/th_wordpress-speed-up_1130.jpg 1200w" sizes="(max-width: 485px) 45vw, 485px" /></figure><div class="related_article__meta archives_post__meta inbox"><div class="related_article__ttl ttl"><span class="labeltext">関連記事</span>WordPressのサイトスピード改善で実施した12の施策とスコア結果まとめ</div><time class="time__date gf">2019.11.30</time></div></a></div>
<p>下記記事では、WordPressのおすすめプラグインを厳選して紹介しています ↓↓<br />
<div class="related_article typesimple"><a class="related_article__link no-icon" href="https://tekito-style.me/columns/wordpress-plugins-roundup"><figure class="eyecatch of-cover thum"><img loading="lazy" decoding="async" width="485" height="283" src="https://tekito-style.me/wp-content/uploads/2020/04/91-wp-plugin-top-485x283.png" class="archives-eyecatch-image attachment-oc-post-thum wp-post-image" alt="" srcset="https://tekito-style.me/wp-content/uploads/2020/04/91-wp-plugin-top-485x283.png 485w, https://tekito-style.me/wp-content/uploads/2020/04/91-wp-plugin-top-1536x896.png 1536w, https://tekito-style.me/wp-content/uploads/2020/04/91-wp-plugin-top-2048x1195.png 2048w, https://tekito-style.me/wp-content/uploads/2020/04/91-wp-plugin-top-300x175.png 300w, https://tekito-style.me/wp-content/uploads/2020/04/91-wp-plugin-top-768x448.png 768w, https://tekito-style.me/wp-content/uploads/2020/04/91-wp-plugin-top-1024x597.png 1024w" sizes="(max-width: 485px) 45vw, 485px" /></figure><div class="related_article__meta archives_post__meta inbox"><div class="related_article__ttl ttl"><span class="labeltext">関連記事</span>おすすめ＆定番のWordPressプラグイン12選まとめ</div><time class="time__date gf undo">2020.07.14</time></div></a></div>The post <a href="https://tekito-style.me/columns/plugin-php-compatibilitychecker">PHP Compatibility Checkerの使い方・設定方法まとめ！PHPバージョンUPで必須のプラグイン</a> first appeared on <a href="https://tekito-style.me">Tekito style.me</a>.]]></content:encoded>
					
		
		
			</item>
	</channel>
</rss>
