Is this link follow or nofollow? Does it pass linkjuice?
-
I have been seeing conflicting opinions about how Google would treat links using 'onclick'.
For the example provided below: Would Google follow this link and pass the appropriate linking metrics(it is internal and points to a deeper level in our visnav)?
=-=-=-=-=-=-=
<div id='<a class="attribute-value">navBoxContainer</a>' class="<a class="attribute-value">textClass</a>">
<div id="<a class="attribute-value">boxTitle</a>" onclick="<a class="attribute-value">location.href='bla</a>h.example.com">
<div class="<a class="attribute-value">boxTitleContent</a>" title="<a class="attribute-value">Text Here</a>"><a href<a class="attribute-value">Text Here</a>"><a ="blah.exam.cpleom">Text Herea>div> ``` =-=-=-=-=-=-= An simple yes/no would be alright, but any detail/explination you could provide would be helpful and very much appreciated. Thank you all for your time and responses.
-
Since the onclick event is a Javascript issue it's to all intents and purposes ignored by the search engines. What counts is whether or not your link appears in the href attribute, and whether or not the link is nofollowed. If you do not have it set to nofollow, there is a slight chance they would follow it, but as stated above, Google is pretty good about parsing javascript links.
-
I didn't know that marking a Good Answer would mark the thread as Answered.
Still looking for responses; hope the 'Answered' tag doesn't cause too many people to pass the topic over.
-
Fair enough! If there are conflicting opinions, I'll be surprised. Google has said since about 2008 or 09 that they are parsing Javascript functionality. Something about creating virtual link structures for spiders, blah blah but that's irrelevant really.
Anyway, good luck!
-
Yes, the code isn't posted here 'as-is'.
I appreciate the quick response and the explination. I will wait for some other voices to chime in with their thoughts but I suspect they will mirror yours (although I am very interested in conflicting opinions if they are out there).
-
Well I'm assuming this code is modified and isn't live anywhere as it's kind of a mess and I don't mean formatting-wise. That said, clearly your question is mainly on the div onClick functionality and whether or not that passes link juice.
To my knowledge, so long as the href is in place you will be fine. Google parses Javascript functionality pretty well and this is one of the simpler JS functions around.
So my answer is: yes.
-
Tabbing seems to have scrunched the code, maybe this is easier to read
<div id='<a rel="nofollow" target="_blank">navBoxContainer</a>' class="<a rel="nofollow" target="_blank">textClass</a>">
<div id="<a rel="nofollow" target="_blank">boxTitle</a>" onclick="<a rel="nofollow" target="_blank">location.href='bla</a>h.example.com">
<div class="<a rel="nofollow" target="_blank">boxTitleContent</a>" title="<a rel="nofollow" target="_blank">Text Here</a>"><a href<a rel="nofollow" target="_blank">Text Here</a>"><a ="blah.exam.cpleom">Text Herea>div>
Hope that helps.
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
-
Links Not Detected by MOZ, AHREFS, GSC-ARE THESE QUALITY LINKS?
Our SEO provider has been creating content (6 blog posts per month as well as building page write ups) and has been promoting that content. Several links per month have been created as a result of this effort. Many of the links have been from commercial real estate publications. I am concerned that the quality of these links is not high enough to improve our ranking. Most links do not appear on AHREFS, Google Search Console or MOZ. Is this a red flag that these links are weak? Ranking and traffic on the site have improved considerably since this provider began the project in April of 2019. They have been writing about 30 pages about New York City. commercial buildings each month in addition to 4 short blog posts and 2 extremely well researched and authoritative blog posts. My concern is that the links are not of sufficient quality to result increased ranking. That the improvement in ranking is solely due to the addition of new content rather than the creation of these links. Basically, that I am incurring the cost on an ongoing basis of an link building campaign with little to no benefit. That being the case, I would shift resources to content creation and increase and improve content rather than develop links with little value. A sample of links are below: Would greatly appreciate some feedback as to whether these are in fact helpful to the domain authority, reputation and ranking of our website. Thanks,
Intermediate & Advanced SEO | | Kingalan1
Alan https://patch.com/new-york/bayside/bayside-queens-priciest-area-retail-office-space-study https://qns.com/story/2019/12/04/these-commercial-streets-in-queens-were-among-the-most-expensive-in-2019/ https://patch.com/new-york/brooklyn/flatbush-ave-priciest-retail-spot-outside-manhattan-study http://thejewishvoice.com/2019/12/07/nycs-most-expensive-commercial-streets-neighborhoods-in-2019-would-surprise-you/ https://atalyst.com/investment-banking-interview-metro-manhattan/0 -
What is future of Link building ? Any link building experts Here ?
Hey Everyone, its Muhammad Umair Ghufran I have one question about Link Building ? As my Knowledge Google Love the Quality content but Link building rank some low quality website Right ? So, what is the future of link building ; please explain indeep with complete reference for better understanding Thanks Regards: Muhammad Umair Ghufran
Intermediate & Advanced SEO | | muhammadumairghufran0 -
Correct keywords Anchor text for links passing
Hi i have some old pages with more link equity, i m planning to key some bestseller in the main content.. my question is on best use of anchor text, can i use the below for eg: Product name is Chloride Exide Safepower Cs 7-12 12V Sealed Battery so i want to use the key word which is "12v 7ah Battery" in anchor text or buy 12v 7ah battery in Anchor text, will this google consider as spam?? Pls suggest
Intermediate & Advanced SEO | | Rahim1190 -
Index, Nofollow Issue
We are having on our site a couple of pages that we want the page to be indexed, however, we don't want the links on the page to be followed. For example url: http://www.printez.com/animal-personal-checks.html. We have added in our code: . Bing Webmaster Tools, is telling us the following: The pages uses a meta robots tag. Review the value of the tag to see if you are not unintentionally blocking the page from being indexed (NOINDEX). Question is, is the page using the right code as of now or do we need to do any changes in the code, if so, what should we use for them to index the page, but not to follow the links on the page? Please advise, Morris
Intermediate & Advanced SEO | | PrintEZ0 -
Widget Links Still Acceptable?
I own a funny video site that is getting about 1-4 of it's videos embedded on various sites daily. In todays form, is widget link still acceptable? This would show up under the video embed. Example: Funny Dog Video From Site Brand Or is it best nowadays to just have Video Provided By Site Brand
Intermediate & Advanced SEO | | superlordme0 -
.GOV Link - same impact on my site's rankings whether link to home or Gov related category?
I own a job site and I am about to get a link from a .GOV. My site has a category called "State Jobs". Should I ask the ".Gov" to link to my homepage or to the state job page and use the anchor text "State Jobs". I understand "State Jobs" page would get a big kick by that being the anchor text and linking to that specific page, but the question I have is this: for my site as a whole (homepage and various categories) would they get around the same "push up" whether the linking is to 1) my homepage with anchor text being my site's name or 2) to the state job specific page and in this case the anchor text would be "State Jobs"? thank you
Intermediate & Advanced SEO | | knielsen0 -
How to Define rel=nofollow Attribute for External Links?
I want to define rel=nofollow attribute for Vista Patio Umbrellas. I have designed narrow by search section on home page. I want to define rel=nofollow attribute for all text links which are available in left navigation. So, what is best solution for that?
Intermediate & Advanced SEO | | CommercePundit0 -
Dark Matter Links
From 2007 - 2004 I worked for Sprint in several positions with my last one being a Corporate Account Manager for fortune 1000 customers. In 2004 I left Sprint after the Nextel merger and created an eCommerce site called thesprintstore.net as a Sprint Nextel preferred partner. I used my inner working knowledge of Sprint to my wonderful advantage and began making 3x my original salary. My desire for more business turned to greed and I began leaking information that consumers loved i.e. phone release dates, price points, warehouse stock levels and tricks of the trade. This garnered me thousands of links from big sites (had no idea at the time) and eventually my site was issued a Cease and Desist order from Sprint's Corporate Headquarters. I recently realized one evening that I had a GEM of a domain with powerful backlinks that I could redirect to my current site TECHeGO.com [staff removed hyperlink]. (Some of the back links are from Engaget, Engaget Mobile, Rimmarkable and even one from Sprint.) The redirection has been in place for months now and I have confirmed that all that sweet Link Nectar is flowing through! I have found it interesting, however, that my back link and referral domain count have never increased leading me to believe that in doing a 301 Redirect existing links become what can only be described as 'Dark Matter Links' i.e. the links are there, simply invisible. Dark Matter Definition: dark matter is matter that is inferred to exist from gravitational effects on visible matter and background radiation, but is undetectable by emitted or scatteredelectromagnetic radiation. Dark Matter Links: dark matter links are visible links that have passed through a 301 redirect which are now inferred to exist but are no longer visible by crawlers? Is there a better definition that could be applied to the term 'Dark Matter Links'?
Intermediate & Advanced SEO | | TECHeGO1