Welcome to WebmasterWorld Guest from

Forum Moderators: DixonJones & mademetop

Message Too Old, No Replies

Finding direct/none in the server log files?

How can I find in my logs information about clicks reported as direct/none?

10:15 am on Aug 2, 2012 (gmt 0)

Junior Member

10+ Year Member

joined:Mar 1, 2003
posts: 41
votes: 0


I have a surge of page views reported by Google Analytics as coming from "direct/none".

I wanted to check my raw server logs and learn more about those.

I have extracted lines containing "-" in the referrer column. Removed lines containing "bot" and "crawler" and was left with very few lines. Most of those lines are irrelevant.

So, how can I find those direct/none pages?


Hanan Cohen
5:29 pm on Aug 2, 2012 (gmt 0)

Senior Member from US 

WebmasterWorld Senior Member lucy24 is a WebmasterWorld Top Contributor of All Time Top Contributors Of The Month

joined:Apr 9, 2011
votes: 244

Do you have Analytics installed on every single page? I tripped over a similar issue in Piwik after realizing that "direct entry" doesn't always mean direct entry. It can also mean that the person came from any page elsewhere on my site that doesn't have analytics code. In my case it meant I had to add the code to the front page, which functions purely as a transfer point so there's no point in tracking it for its own sake.

Picking out non-robot visits with blank referer is the right way to do it. Depending on your server and other obscure variables it might come through as either "-" or a completely empty "" so make sure you're getting both. You may also need to screen for spaces on both sides of "" to get rid of search queries containing literal question marks.
9:18 am on Aug 12, 2012 (gmt 0)

Junior Member

10+ Year Member

joined:Mar 1, 2003
posts: 41
votes: 0

OK, I have found the problem.

Our advertising agency is using a third-party server that display ads on different sites. A correct referrer value looks like this:


Somehow, I have more than 10k lines in the server log file that have a referrer value that looks like this:


They are truncated somewhere in the middle.

Naturally, Google Analytics don't know what to do with them.

I don't know whose fault it is, their server or mine but now I know what to look for.

Thanks for your help,

Hanan Cohen

Join The Conversation

Moderators and Top Contributors

Hot Threads This Week

Featured Threads

Free SEO Tools

Hire Expert Members