워드프레스 웹사이트 속도/성능 향상시키기

워드프레스 웹사이트 구축시 테마 선정할 때 최적화가 잘 이루어진 것을 선택하는 것이 중요합니다.
그리고 아래와 같은 설정 및 플러그인 설치/관리가  성능향상에  도움을 주게됩니다.
 

1. 워드프레스 고유주소 설정
고유주소 설정을 기본이 아닌 다른 유형으로 셋팅하세요.
문자열이 나오는 고유주소보다는 숫자가 나오는 쪽이 성능이 더 높습니다. 가능하면 숫자가 먼저 나오는 “날짜와 이름”, “월과 이름”, “숫자”중 하나를 선택하여 설정하면 서버 캐시 기능을 제공하는 플러그인 설치 시 원활하게 진행할 수 있습니다.

 

2. 서버에 직접 캐시 설정
서버에 접근한 후 도메인 루트에서 .htaccess 파일을 찾아 아래 내용을 삽입하세요.
## 서버 캐시 기간 설정 ::: EXPIRES CACHING ##
<IfModule mod_expires.c>
ExpiresActive On
ExpiresByType image/jpg “access plus 1 year”
ExpiresByType image/jpeg “access plus 1 year”
ExpiresByType image/gif “access plus 1 year”
ExpiresByType image/png “access plus 1 year”
ExpiresByType text/css “access plus 1 month”
ExpiresByType application/pdf “access plus 1 month”
ExpiresByType text/x-javascript “access plus 1 month”
ExpiresByType application/x-shockwave-flash “access plus 1 month”
ExpiresByType image/x-icon “access plus 1 year”
ExpiresDefault “access plus 7 days”
</IfModule>
## 서버 캐시설정 ::: EXPIRES CACHING ##
## 브라우져 캐쉬 기간 설정  ##
<IfModule mod_headers.c>
Header set Connection keep-alive
# Cache-control headers
# 2 HOURS
<filesMatch “*”>
Header set Cache-Control “max-age=7200, must-revalidate”
</filesMatch>
# 480 weeks – 290304000
# 2 WEEKS
<filesMatch “\.(ico|pdf|flv|jpg|jpeg|png|gif|js|swf)$”>
Header set Cache-Control “max-age=1209600, public”
</filesMatch>
# 1 DAY
<filesMatch “\.(css)$”>
Header set Cache-Control “max-age=86400, public, must-revalidate”
</filesMatch>
# 2 DAYS
<filesMatch “\.(xml|txt)$”>
Header set Cache-Control “max-age=172800, public, must-revalidate”
</filesMatch>
# 2 HOURS
<filesMatch “\.(html|htm)$”>
Header set Cache-Control “max-age=7200, must-revalidate”
</filesMatch>
<FilesMatch “\.(gif|jpg|png|ico|css|js|pdf|txt)$”>
Header append Cache-Control “public”
</FilesMatch>
</IfModule>
## 브라우져 캐쉬 기간 설정  ##

 

워드프레스 운영을 맡길 곳을 찾는 중이라면 — 옮길 수 있는지만 먼저 확인 →
3. 리비전, 휴지통 기간 설정
wp-config.php 파일에 아래 내용 삽입하세요.
/*리비전수 제한 5일 ::: 기본 무제한*/
define( ‘WP_POST_REVISIONS’, 5 );
/*휴지통 관리 7일 ::: 기본 30일 */
define (‘EMPTY_TRASH_DAYS’, 7);

 

4. 핑백과 트랙백 기능 설정
핑백과 트랙백 기능을 끄면 속도향상에 도움이 됩니다. 기능사용여부를 판단하여 설정하세요.
관리자 사이트 로그인 -> 설정 -> 토론 -> ‘새로운 글에 다른 블로그에서 오는 링크알림(핑백이나 트랙백)을 허용’ 부분을 체크 해제

 

5. HTML/CSS/JS 최적화
Autoptimize 플러그인은 파일들을 최적화해 사이즈를 줄이거나 통합하거나 로딩 순서를 조정해 최적의 방식으로 페이지가 표현되도록 합니다. (주의: 이 플러그인을 설치했을 때 레이아웃이 깨지는 현상 혹은 기능이 비정상적으로 작동하는 현상이 발생할 수 있습니다.)

 

6. 이미지 압축 및 Lazy Laoding관련 플러그인 사용
이미지를 많이 사용하는 사이트의 경우  이미지 압축 및 Lazy Laoding기능의 플러그인 설치 통하여 사이트의 속도향상에 도움이 됩니다.
BJ Lazy Load 플러그인은 사용자 정의 설정형 플러그인으로  최적화 된 이미지 제공 및 반응형 디자인에서 축소된 이미지를 자동으로 제공합니다.

 

7. 플러그인 관리
플러그인을 많이 설치하면 할 수록 워드프레스가 느려지게 될 가능성이 높아지므로 불필요한 플러그인은 삭제하세요.
We value your privacy

We use cookies to make this website work and, with your permission, to understand how it is used and to measure our advertising. Necessary cookies are always on. Analytics and marketing cookies stay off unless you choose “Accept all” or switch them on under “Customize”. You can change your choice at any time from “Cookie settings” at the bottom of the page. Read our Privacy Policy.

Strictly necessaryNeeded for the site to work: security, your language choice and remembering your cookie settings. These cannot be switched off.
Always active