To determine how much traffic (how many visitors) your site can handle, you usually run a load test that simulates a certain number of users accessing your site at the same time, then reports how fast your site serves web pages to those simulated users. Many people encounter a problem when they want to do this; Most, if not all, load testing systems want you to specify how many concurrent simulated users should be used in the load test, but most people only know how many visitors their website has per day or per month. The question that comes up is then "how to convert visits per month to concurrent users?"
If we start with the source of information about site visits, Google Analytics is very popular as a means of keeping track of website traffic. It shows you lots of interesting information about your visitors and what they do on your site, and is used by a lot of site administrators today. Because of this, I will use Google Analytics in my examples below.
One thing you can see on the Google Analytics dashboard is the number of visits your site has had the last month ("Visits"). This is of course interesting as it gives you an idea of how much traffic your webserver has to handle in a month. However, it doesn't tell you the peak traffic load your server has to handle at some specific point during the month. Most people will want to make sure their server can handle the peak traffic load (and more) so as not to risk losing business because of slow page load times.

Peak traffic can vary a lot between days, depending on many different circumstances. To view the number of visits per day in Google Analytics, you just click the "Visits" link on the dashboard (circled on the image above). For our own site - loadimpact.com - we see that high-traffic days (for us typically tuesday-thursday) see 100-200% more traffic than low-traffic days (typically saturday and sunday). Your mileage may vary, of course. It all depends on the type of site and the type of users. Below we have selected a 7-day period and clicked on the "Visits" link for our example site.

We can see in this example that on monday, january 26, the site had a traffic peak with 622 visits.
If you find a single day where you have a lot of traffic, you can then proceed to find out something that is even more interesting - namely what the peak traffic is for any single hour that day. This is a bit more complex in Google Analytics, however - you have to create a custom report. The custom report interface is available through a link in the left hand menu:

When you're in the custom report interface you have to create a new custom report, then select what things you want your report to contain. You can specify different Metrics and Dimensions to use in the report. We will specify a single Metric and a single Dimenion in our report. The Metrics and Dimensions are grouped in different categories. The categories we will use are "Site Usage" and "Visitors". You can see them circled on the image below.

First, we click on the Metric category "Site Usage", which brings up a range of metrics we can use. Scroll down until you find the "Visits" metric, then drag it over to the empty metric box to the right.

Then close the "Site Usage" metric category and instead open the "Visitors" dimension category. Under that category you'll find a dimension called "Hour of the day". Drag this dimension over to the empty dimension box to the right.

Now you have a report that can show you the number of visits distributed over the different hours of the day, for the time period you have selected. Save the report and try viewing it.
Generating this report for the day you found that had the highest number of visitors, will likely show what the peak number of visits per hour your site has. Maybe you will see that at 3pm on that day, you had 1,000 visits. This value, plus a little margin, is very possibly the target traffic level you want your site to be able to support (while still responding reasonably fast, so users don't have to wait for pages to load).
On the screenshot above we can see that on the day selected, we got the most visits at 1600 hours (4:00 pm to 4:59 pm). This is the traffic for the peak hour of the peak day, so it is a fairly good approximation of the maximum traffic our site has seen.
When you have determined what number of visits per hour you want your site to be able to handle, you should of course test if your site can handle that level of traffic (with reasonably fast page load times). To do this, you have to run a load test. The problem then is that most, if not all, load testing systems will want you to specify how many concurrent ("simultaneous") users you want to subject your site to. They don't talk about users or visits per month, per day, or even per hour. So how do we translate those figures to concurrent users?
Converting visits per hour to concurrent users:
concurrent_users = (hourly_visits * time_on_site) / 3600
So, if you have 1,000 visits per hour, and each visitor stays on the average 3 minutes (180 seconds) on your site, that means you would have (1000 * 180) / 3600 = 50 concurrent users.
Note that you need to use "visits", and not "unique visitors", when calculating the number of concurrent users. A single physical person may visit a site twice during an hour, which will of course cause twice the load on the web server. So we want to count the number of times the site has been visited, and not the number of unique persons that visit the site.
Time on site
The time on site parameter is the average time a user spends on the site. This is also something Google Analytics will tell you. It is the "Avg. Time on Site" value shown on the dashboard.
To translate visits per month to concurrent users:
concurrent_users = (monthly_visits * time_on_site) / (3600 * 24 * 30)
So, you just divide by the number of seconds in a month, rather than as before the number of seconds in an hour.
Now, when you know how many concurrent users you want your site to be able to handle, you can set up your load test. If, for example, you calculate that your site experiences a maximum of 50 concurrent users, but you want to test that the site can handle occasional peaks of, say 50% more traffic, then you want to verify that your site can handle up to 75 concurrent users. A reasonable load test setup might then be a ramp-up load test that tests four different load levels, starting at 25 concurrent simulated users, ramping up to 50, 75 and finally 100 concurrent users. That test would show you what response times (page load times) users would experience in low (25 users) and high (50 users) traffic conditions. The load levels 75 and 100 simulated users would also show what happens when the site/service grows or you see an exceptional burst of traffic due to some external event (maybe a big news blog writing an article about your site, generating a lot of extra traffic).
Thanks to Ditlev at VPS.NET who gave us the idea for this article. He actually wrote one of his own also, that you should look at if nothing of this made any sense. It is available here

The mistake we made in our first test is that 70-450 we didn't realize the significant difference between the two different disk based page caching methods available. There's "Basic" caching which is the one we tested, and there's "Enhanced mode". In Basic mode, W3TC will work pretty much the same way as the 70-453 standard wp-cache plugin which involves invoking a PHP script. In our server benchmark, we've already seen that our server will consume in the region of 70-528 latest dumps 80ms for doing that so we're glad if we could avoid it in the elegant manner that Wordpress Super Cache does.
This article was exactly what I was looking for. Thanks for the post
Nice article, thanks for sharing your approach !
Thanks for this VERY helpful post!
Rather than building a Google custom report to obtain the number of visits by hour, can't you just select "graph by hour" (located under the date range)?
This seems to give the same information as the custom report.
Thanks for this VERY helpful post.
Rather than building a custom Google report to show visits by hour, can't you simply select "graph by hour" (underneath the date-range control), when you're viewing the Visits page?
Good reference, just a caveat about interpreting "Visits" when performing page level analysis, ie dimensions which includes "page" and "hours of day" in the custom report. In such reports "Visits" are often much less than page views and unique visitors, this is because at page level "Visits" seem to count the number of sessions started from that specific page (="Entrances").
In such cases Pageviews may be better.
Src:
http://www.google.com/support/forum/p/Google%20Analytics/thread?tid=63f0fb82b9db2733&hl=en
@Steve: Thanks for the praise, and you're right. I think that when the article was written there wasn't a "graph by hour" option in GA. We should probably write an updated version of the article - I'll put it on the TODO list /Ragnar
Nice article. Note that you don't need to make a custom report to see the by-hour data, but it is hard to find. If you go to the Visits report (or Pageviews, or a number of other supported reports) and then filter to show a single busy day, then you click the picture of a clock next to Graph by on the right. You should see a bar graph showing the number of visits/pageviews/etc by hour, for the day selected.
thanks so much for helpful post
I have found this article helpful, but I am a bit confused.
When looking at Google's new RealTime (beta) reports, the numbers do not add up.
During an hour yesterday (2pm o'clock hour) We got hit with a spike of traffic. For nearly the entire hour Google's realtime counter was never below 120 and for much of the hour it was between 175-200 users.
When using the calculations above from our analytics report for that same our we had 1225 'vistis' with an average time on site being 1:41. with those numbers and the above calculation, our concurrent users average is only ~34. Any thoughts about where the discrepancy is?
@Kevin:
Your numbers do seem strange. Might it be that you have 1225 "unique visitors" and the total number of "visits" is actually a lot higher for the hour? We haven't looked so much at Google's realtime analytics and they are still in beta, so I guess there might be some reliability issue there also.
If you have 120 visitors at any one point during the hour, and each visitor stays on the site for less than 2 minutes, that means you have to have 120 new visitors coming in every 2 minutes. If you don't have an inflow of new visitors that is at that level, you would not have 120 concurrent visitors, given the average time on site that you're quoting.
There are 60 minutes in an hour, which means that you get 120 new visitors 30 times during that hour, for a total of 120x30=3600 visitors. If you didn't get at least that many visits (conservatively calculated, you need more than that as your average time on site was only 1:41 and you said 120 concurrent was the lowest level you had seen) during the hour you would not be able to have even an average of 120 concurrent users.
My conclusion is that one of your figures must be wrong - either 1225 visits/hour is too low, or average time on site 1:41 is too low, or the realtime concurrent user figure reported is too high. Please get back to us if you find out what the problem is!
/Ragnar, Load Impact