Html and css errors - what do SE spiders do if they come across coding errors? Do they stop crawling the rest of the code below the error
-
I have a client who uses a template to build their websites (no problem with that) when I ran the site through w3c validator it threw up a number of errors, most of which where minor eg missing close tags and I suggested they fix them before I start their off site SEO campaigns.
When I spoke to their web designer about the issues I was told that some of the errors where "just how its done" So if that's the case, but the validator still registers the error, do the SE spiders ignore them and move on, or does it penalize the site in some way?
-
Ryan, thanks so much for taking the time to answer, and so comprehensively too, I really appreciate it.
My client came around after I suggested that Getting quality backlinks to a website full of coding errors was like hanging a crystal chandelier in a toilet!! and that they where tying one of my hands behind my back by not sorting it out. Perhaps not the most expert answer but they got the point.
Thanks for some great information and a great answer all round.
-
**When I spoke to their web designer about the issues I was told that some of the errors where "just how its done" **
Are you OK with that response? If your client asked you why you took a course of action on their site would you expect the client to accept "it's just how things are done"?
Generally speaking, sites should use valid code. The W3C is the international body which establishes coding standards. They are made up of a group of people including representatives from Microsoft (IE), Google (Chrome), Mozilla (FireFox), Apple (Safari), etc. Valid code should appear correctly in all browsers.
Generally speaking again, a developer who writes valid code is following best coding practices. The code can be more easily reviewed by other developers. When invalid code is used, it is often due to sloppy coding practices such as not closing tags, using deprecated tags, not being familiar with the particular encoding of the language in use, etc. When I ask a developer why the code is not valid and the response is "it's just how things are done" the translation often is "I lack the knowledge / training / experience to write valid code".
Ok, now that I angered many developers let me take the flip side of the coin. Google.com does not validate. What's up with that? Well, you know the development team at Google is among the best in the world. Their project leaders likely have their doctorate degrees or at least master degrees. Many of them are authors of books on best coding practices. These guys clearly understand all the rules and are able to go past them to achieve better results in a given area, such as speed optimization which Google treasures.
In summary, leading companies can often employee the upper echelon of employees who thoroughly understand the rules and can break them for their benefit. Unfortunately, that does not trickle down to every day developers. Most of them do not have the knowledge / training / experience to make those calls and are simply either using sloppy coding practices or they are not taking the time to research other alternatives. They have deadlines and they jump on whatever works.
what do SE spiders do if they come across coding errors? Do they stop crawling the rest of the code below the error
The results vary based on the Search Engine and the type of error. Here are some examples:
1. There are some errors due to the "&" being used instead of the binary operator "&". Sometimes there are issues with various code where the & character may have another purpose and the interpreter may try to perform an operation on the code such as concatenation rather then simply reading the & as a character.
2. In html,
is a perfectly valid tag. In XHTML, there is a rule that any tags which are not used in a pair should be end in />. In other words, the correct form of the
tag in XHTML is
. If you have an XHTML document which generates 20 errors, and all of those errors are due to the developer using
instead of
then a crawler should handle that issue very well. The crawler recognizes and understands the
tag even though it is technically invalid code.3. An open div tag can cause a variety of issues. It all depends on what operation the div is performing. It could be very minor or a major issue.
Google does a great job of handling invalid code. Bing seems less tolerant of coding errors and much more selective.
A video you will likely enjoy: http://www.youtube.com/watch?v=FPBACTS-tyg
Summary
You should strive for valid code with your site. Coding errors can cause a variety of issues including making it harder for other developers to work on the site, causing the site to appear incorrectly in various browsers or devices, negatively impacting page loading times, and impeding search engine crawlers. It is not possible to say without a review of the specific error. While I do not develop websites, I do project manage the development of many sites. When the site is complete, the goal is to not have any validation errors. If a handful of errors exist, I request for the developer to try to eliminate them. If they cannot, I request an error-by-error explanation of why the error exists and why it cannot be eliminated. The result is a site which appears correctly in all browsers, is correctly crawled and interpreted by search engines, and is easily maintained by various developers.
A final note: just because a page validates does not mean it is developed well, and the reverse is true also. I would say with the exception of the top 1% of sites which are developed by teams of very well trained and experienced web professionals, sites which validate are likely better designed and maintained then sites which do not validate.
Got a burning SEO question?
Subscribe to Moz Pro to gain full access to Q&A, answer questions, and ask your own.
Browse Questions
Explore more categories
-
Moz Tools
Chat with the community about the Moz tools.
-
SEO Tactics
Discuss the SEO process with fellow marketers
-
Community
Discuss industry events, jobs, and news!
-
Digital Marketing
Chat about tactics outside of SEO
-
Research & Trends
Dive into research and trends in the search industry.
-
Support
Connect on product support and feature requests.
Related Questions
-
Strange error on my website
Hi Wondering if anyone could help out here please. I tried to crawl my website using screaming frog and got a 500 error warning (odd considering it worked yesterday). I tried google speed test and got the following message - PageSpeed Insights received a 500 response from the server. To analyze pages behind firewalls or that require authentication. However, it also crawled the site and gave me a score of 70/100. It showed the site thumbnail, as normal. This was updated this morning and it showed the latest one so must have crawled. I can access the site, as can my 'people', the site is getting hits from real users in Google Analytics so must be working. Am very puzzled how the site can be working and not be working at the same time! If possible i would rather not share the url. The site is a test of concept and is very messy looking. it is more a test to see what happens if i do x... Many thanks Carl
On-Page Optimization | | daedriccarl0 -
How to Fix Google Webmasters Soft 404 Errors for Wordpress Site?
I am getting Soft 404 errors in my Google Webmasters Tools don't know how to fix it the site in on WordPress CMS the site is "http://appdictions.com/" i am getting errors in the http://appdictions.com/members section...suggestion to fix the issue will be appreciated..
On-Page Optimization | | preferati0 -
Dealing with Not Found errors
Hi, I have a problem with Google Webmaster, it reported that I have many errors 404 Not Found.
On-Page Optimization | | JohnHuynh
I have detected and found the links are coming from my site, I have fixed them and submit a new sitemap to google again. Then, I wait a few days, google still report errors 404 Not found same as before. I don't know why? Please help!0 -
404 Error to homepage
Is there any risk of forwarding 404 links directly to homepage. I already have 404 page but now google showing you have lots of 404 links and some of them i can't control to fix this issue. Is there any problem if i do so for SEO ?
On-Page Optimization | | chandubaba0 -
When it comes to duplicate page content how do I deal with correcting it. Its a dynamic e commerce site.
I am under the impression that with ecommerce sites this happens often and that there's a plug in or just simply not worry about it since queries will often find similar conent.
On-Page Optimization | | Wayne_c0 -
Hi . I have a question regarding a surge in 302 temporary direct errors following reactivation of my site reviews.
Hi. i submitted the following question to the support team at volusion regarding a large number of 302 temporary redirects on the SEOMOZ crawl of following the reactivation of product reviews on my website. Here is the question and their response. Any opinions. Thanks TRANSCRIPT: Hi Howard, Looking at the link you have referenced, this page is unable to be accessed unless you are logged into your site, so SEO isn't applicable for the page. We would not be able to change the 302 redirect for this page. Please don't hesitate to contact us if you have any further questions. Thanks,
On-Page Optimization | | mrkingsley
Meredith G.
Here for you 24x7x365 Volusion Support Check out our online support: http://support.volusion.com | 4 days ago (102hrs ago) [8/19/2012 10:06:00 AM] by Customer | | Hi . I had a report of 302 temporary redirects when SEO moz did a simulated site crawl. This is an example of the address of one of the many 302 temporary redirect errors which I think consume link juice or have some type of negative effect on SEO. http://www.mrgrabbar.com/reviewhelpful.asp?ProductCode=GT100&ID=562&yes=yes Since it is a live link I cannot seem to redirect it with a 301 redirect in the redirect manager. Is there anything I can do to handle these temporary redirects. They only are appearing now since I reactivated my reviews and I am concerned about the SEO effect that this may soon have.0 -
Not making a change of the 100's in crawl Diagnostic
Based on the PRO crawl Diagnostics – if we don’t make a change on 1 page, does that just affect the SEO on that one page, or does it affect the SEO on all pages of the site? E.g. If we get a “Too many on page links” for a certain page that we don’t really want to rank for – does not fixing that particlaur page affect the site as a whole? Hope I explained this ok..
On-Page Optimization | | inhouseninja0 -
Content within JavaSccript code
I know that it is not a good practice to inlcude SEO content within JavaScript, but are there exceptions to what Google can spider or is it best to just avoid completely?
On-Page Optimization | | mjmorse0