81 votes
Accepted

How do I open the JavaScript console in different browsers?

Chrome Opening the “Console” panel of Chrome’s DevTools: Windows and Linux: Ctrl + Shift + J Mac OS: Cmd + Opt + J Note: In addition to the “Console” panel, there also exists a smaller slide-up ...
32 votes

Is inline JavaScript good or bad?

On my currency conversion site, the majority of sessions are single page views. This is because users can do their currency calculation directly on the landing page (all the calculation is handled ...
user avatar
29 votes
Accepted

How does CloudFlare's Rocket Loader actually work (and how can a developer ensure compatibility)?

CloudFlare describes Rocket Loader like this... Rocket Loader is a general-purpose asynchronous JavaScript loader coupled with a lightweight virtual browser which can safely run any JavaScript ...
15 votes
Accepted

Is inline JavaScript good or bad?

Inline JavaScript increases download times for the page, which is not good. With a call to a .js file, at least these can be parallel calls and content download times decreased. Yes there are times ...
user avatar
  • 32.5k
14 votes

Does the Google spider render JavaScript?

Google now officially processes JavaScript. In order to solve this problem, we decided to try to understand pages by executing JavaScript. It’s hard to do that at the scale of the current web, but we ...
user avatar
  • 85.8k
14 votes

Is inline JavaScript good or bad?

It's not necessarily bad to have JavaScript within your HTML file but you must make a judgement call on it. It is bad if you have a large amount of JavaScript being used across multiple pages. In ...
user avatar
  • 595
11 votes
Accepted

Lazy loading images and effects on SEO

I've never seen image lazy loading have any negative impact on web search rankings. Improving the perceived performance of your site for users can really help your rankings. When fewer people bounce ...
user avatar
11 votes

Anyone still using JavaScript disabled?

From the info I found through this question on SO I guess that between 0.2 and 2% of users have JavaScript disabled, depending on the country. I'd say take 1% as a rule of thumb. Whether you should ...
user avatar
  • 1,560
10 votes
Accepted

How do I prevent Google from indexing text that is generated by JavaScript?

robots.txt can block JavaScript files from Googlebot. http://www.robotstxt.org/ has more information about how to construct a robots.txt file. You could put your JavaScript that shows the password ...
user avatar
  • 126
8 votes
Accepted

restricting Google Maps js API keys to just my domain

Google changes this around every now and then, and whenever they do I have to 're-find' where each of the settings are. So you're not alone! You're right that a browser key is essentially 'public' ...
user avatar
  • 1,231
8 votes
Accepted

Server-side rendering for search engines only (SEO)

Can I just send pre-rendered HTML, using phantomjs or other headless browser, to the google bot? In short... no you shouldn't. Google's stance on differing versions for visitors and search bots is ...
user avatar
  • 32.6k
7 votes

Most website visitors don't have Java enabled

Java != Javascript Javascript is a scripting language supported by the overwhelming majority if interactive browsers. Note that I said Interactive browsers - most bots will have extremely limited - if ...
user avatar
  • 5,825
6 votes

Tracking logged in vs. non-logged in users in Google Analytics

Use custom dimensions in Google Analytics. First, navigate to the "admin" section of Google Analytics' web portal, click "Custom Definitions", then "Custom Dimensions" under the property you're ...
user avatar
  • 1,446
6 votes

403 Error Fetching Image with JS

When I try to get a particular image on a remote domain via JavaScript I get a 403 error. Likely answer: The site in question has protection against "leeching" / hotlinking. i.e. It checks to see ...
user avatar
  • 2,299
6 votes
Accepted

How to hide a JavaScript popup for Googlebot?

Never treat Googlebot any different than your real users Google's bots that visit your site should be treated just as any other user and therefor attempting to hide content can actually harm your ...
user avatar
  • 32.6k
6 votes

If I dynamically add a robots meta tag (via JS) will Google and other search engines recognize it?

No. Google may sometimes execute Javascript to determine content, but it's a very bad idea to rely on Javascript for your site to be crawled as you want it to be.
user avatar
6 votes

Are Googlebot and other search engine crawlers able to detect if element is hidden after page load by JavaScript?

Googlebot now renders pages and views the page as a user sees it when it loads, including applying CSS and running JavaScript. Google will detect text that is hidden using either CSS or JavaScript. ...
user avatar
6 votes

How to hide h1 and h2 tags using JavaScript while still having them for SEO

You can't hide h1 and h2 tags (or any text for that matter) and still have them apply positively to SEO. For several years now, Google has been trying to index precisely what the user sees. Google is ...
user avatar
  • 40.9k
6 votes
Accepted

Does Google count external Javascript or CSS files as backlinks?

Those are not links so they aren't counted as such. They're URLs of resources which are very different things. Hosting such a resource offers no direct SEO value but being known as a reliable host can ...
user avatar
  • 85.8k
6 votes
Accepted

Do I need to add the Google Tag Manager if I already have Google Analytics?

you can leave the global site tag tracking code snippet on your site, just do not also configure tags for GA pageview tracking within GTM. If it were me, I would remove the global site tag tracking ...
user avatar
  • 3,358
5 votes

Is inline JavaScript good or bad?

I'm a Yii developer and I can tell you, that Yii has nothing to do with this. It is completely on developer side, whether he or she put Javascript code to a separate file and register it with HTML (...
user avatar
  • 173
5 votes

Does e.preventDefault on link prevent the page from being crawled?

The pages will be found and most likely be crawled. You're not far from the truth if you assume bots don't use Javascript. A crawler works similar to this: Go to a webpage and get it's contents ...
user avatar
  • 6,736
5 votes
Accepted

Do cryptocurrency webminers in a blog violate adsense policies?

Google's Adsense policy does not touch upon Crypto Currency Browser miners directly but it is clear that either malware or anything else that interferes with site navigation is considered a breach of ...
user avatar
  • 32.6k
5 votes
Accepted

Is bad for SEO if browser need to run synchronous JS to get content?

Google doesn't care about the name of the tags in your body section - the crawler renders the site using chrome itself (including synchronous js) so it cares for whatever is printed to the screen. You'...
user avatar
5 votes
Accepted

What are the benefits of utilizing a Web Server vs opening an HTML file directly via your browser

I tend to use a development server rather than file:/// URLs even when developing static sites. There are quite a few things that don't work from file:/// URLs. Just the first two points in my list ...
user avatar
5 votes

How to pass JavaScript errors to Google Analytics using Google Tag Manager

Yes, the article is not quite complete. Any trigger has to be matched with a tag, in this case a Universal Analytics Event tracking tag (I do not believe there is another appropriate way to send it). ...
user avatar
  • 2,001
5 votes

Do I need to add the Google Tag Manager if I already have Google Analytics?

You need to add your Google Tag Manager code in your website. Then, you have two options: Leave it, don't do anything else. Your Google Analytics code will remain as it is and FB Pixel will be added ...
user avatar
5 votes

Does using onclick to redirect parameters impact SEO?

Based on Links Crawable Guidelines, the link will be crawled as https://www.example.com/, because Google can not follow link from onclick attributes. Google search central says: Google can follow ...
user avatar
4 votes

Troubleshooting websites on gaming consoles

I think the solution you're looking is a HTTP debuging proxy like Fiddler. You could then set the console's proxy settings to point to the computer running Fiddler. From there, you'll be able to view ...
user avatar
  • 141

Only top scored, non community-wiki answers of a minimum length are eligible