Stay organized with collections
Save and categorize content based on your preferences.
Thursday, February 09, 2012
It's a moment any site owner both looks forward to, and dreads: a huge surge in traffic to your
site (yay!) can often cause your site to crash (boo!). Maybe you'll create a piece of viral
content, or get Slashdotted, or maybe Larry Page will get a tattoo and your site on tech tattoos
will be suddenly in vogue.
Many people go online immediately after a noteworthy event—a political debate, the death of a
celebrity, or a natural disaster—to get news and information about that event. This can cause a
rapid increase in traffic to websites that provide relevant information, and may even cause sites
to crash at the moment they're becoming most popular. While it's not always possible to anticipate
such events, you can prepare your site in a variety of ways so that you'll be ready to handle a
sudden surge in traffic if one should occur:
Prepare a lightweight version of your site. Consider maintaining a lightweight version
of your website; you can then switch all of your traffic over to this lightweight version if you
start to experience a spike in traffic. One good way to do this is to have a mobile version of
your site, and to make the mobile site available to desktop/PC users during periods of high
traffic. Another low-effort option is to just maintain a lightweight version of your home page,
since the home page is often the most-requested page of a site as visitors start there and then
navigate out to the specific area of the site that they're interested in. If a particular
article or picture on your site has gone viral, you could similarly create a lightweight version
of just that page.
A couple tips for creating lightweight pages:
Exclude decorative elements like images or Flash wherever possible; use text instead of
images in the site navigation and chrome, and put most of the content in HTML.
Use static HTML pages rather than dynamic ones; the latter place more load on your servers.
You can also cache the static output of dynamic pages to reduce server load.
Take advantage of stable third-party services. Another alternative is to host a copy of
your site on a third-party service that you know will be able to withstand a heavy stream of
traffic. For example, you could create a copy of your site—or a pared-down version with a focus
on information relevant to the spike—on a platform like
Google Sites or
Blogger; use services like
Google Docs to host documents or
forms; or use a
content delivery network
(CDN).
Use lightweight file formats. If you offer downloadable information, try to make the
downloaded files as small as possible by using lightweight file formats. For example, offering
the same data as a plain text file rather than a PDF can allow users to download the exact same
content at a fraction of the filesize (thereby lightening the load on your servers). Also keep
in mind that, if it's not possible to use plain text files, PDFs generated from textual content
are more lightweight than PDFs with images in them. Text-based PDFs are also
easier for Google to understand and index fully.
Make tabular data available in CSV and XML formats. If you offer numerical or tabular
data (data displayed in tables), we recommend also providing it in CSV and/or XML format. These
filetypes are relatively lightweight and make it easy for external developers to use your data
in external applications or services in cases where you want the data to reach as many people as
possible, such as in the wake of a natural disaster.
We'd love to hear your tips and tricks for weathering traffic spikes—come join us in our
Webmaster Help Forum.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],[],[[["\u003cp\u003eWebsites can experience sudden traffic surges due to viral content, noteworthy events, or mentions by popular figures.\u003c/p\u003e\n"],["\u003cp\u003ePrepare for traffic spikes by creating a lightweight version of your site, utilizing stable third-party services, and offering downloadable content in smaller file formats.\u003c/p\u003e\n"],["\u003cp\u003eConsider using a mobile version of your website or a lightweight homepage to handle increased traffic, excluding decorative elements and using static HTML pages to reduce server load.\u003c/p\u003e\n"],["\u003cp\u003eHost copies of your site on platforms like Google Sites or Blogger and utilize services like Google Docs for documents to leverage third-party stability during traffic surges.\u003c/p\u003e\n"],["\u003cp\u003eOffer downloadable information in lightweight formats like plain text or text-based PDFs to minimize file size and server load.\u003c/p\u003e\n"]]],["Site owners can prepare for traffic surges by creating a lightweight version of their site, such as a mobile version or a basic homepage, using static HTML pages, and excluding heavy elements like images. Leveraging third-party services like Google Sites or content delivery networks is also recommended. Using lightweight file formats like text files over PDFs and offering tabular data in CSV/XML formats can minimize server load. These steps help maintain site stability during unexpected spikes in traffic.\n"],null,["# Preparing your site for a traffic spike\n\nThursday, February 09, 2012\n\n\nIt's a moment any site owner both looks forward to, and dreads: a huge surge in traffic to your\nsite (yay!) can often cause your site to crash (boo!). Maybe you'll create a piece of viral\ncontent, or get Slashdotted, or maybe Larry Page will get a tattoo and your site on tech tattoos\nwill be suddenly in vogue.\n\n\nMany people go online immediately after a noteworthy event---a political debate, the death of a\ncelebrity, or a natural disaster---to get news and information about that event. This can cause a\nrapid increase in traffic to websites that provide relevant information, and may even cause sites\nto crash at the moment they're becoming most popular. While it's not always possible to anticipate\nsuch events, you can prepare your site in a variety of ways so that you'll be ready to handle a\nsudden surge in traffic if one should occur:\n\n- **Prepare a lightweight version of your site.** Consider maintaining a lightweight version of your website; you can then switch all of your traffic over to this lightweight version if you start to experience a spike in traffic. One good way to do this is to have a mobile version of your site, and to make the mobile site available to desktop/PC users during periods of high traffic. Another low-effort option is to just maintain a lightweight version of your home page, since the home page is often the most-requested page of a site as visitors start there and then navigate out to the specific area of the site that they're interested in. If a particular article or picture on your site has gone viral, you could similarly create a lightweight version of just that page. \n A couple tips for creating lightweight pages:\n - Exclude decorative elements like images or Flash wherever possible; use text instead of images in the site navigation and chrome, and put most of the content in HTML.\n - Use static HTML pages rather than dynamic ones; the latter place more load on your servers. You can also cache the static output of dynamic pages to reduce server load.\n- **Take advantage of stable third-party services.** Another alternative is to host a copy of your site on a third-party service that you know will be able to withstand a heavy stream of traffic. For example, you could create a copy of your site---or a pared-down version with a focus on information relevant to the spike---on a platform like [Google Sites](https://sites.google.com/) or [Blogger](https://www.blogger.com/); use services like [Google Docs](https://docs.google.com/) to host documents or forms; or use a [content delivery network](https://www.google.com/search?q=content+delivery+network) (CDN).\n- **Use lightweight file formats.** If you offer downloadable information, try to make the downloaded files as small as possible by using lightweight file formats. For example, offering the same data as a plain text file rather than a PDF can allow users to download the exact same content at a fraction of the filesize (thereby lightening the load on your servers). Also keep in mind that, if it's not possible to use plain text files, PDFs generated from textual content are more lightweight than PDFs with images in them. Text-based PDFs are also [easier for Google to understand and index fully](/search/blog/2011/09/pdfs-in-google-search-results).\n- **Make tabular data available in CSV and XML formats.** If you offer numerical or tabular data (data displayed in tables), we recommend also providing it in CSV and/or XML format. These filetypes are relatively lightweight and make it easy for external developers to use your data in external applications or services in cases where you want the data to reach as many people as possible, such as in the wake of a natural disaster.\n\n\nWe'd love to hear your tips and tricks for weathering traffic spikes---come join us in our\n[Webmaster Help Forum](https://support.google.com/webmasters/community).\n\n\nPosted by\n[Susan Moskwa](/search/blog/authors/susan-moskwa),\nWebmaster Trends Analyst"]]