I am new to AngularJS and due to some technical issues or maybe I'm just not aware of the right way, I am facing SEO related issues. So at the moment I plant a proxy server running behind the main server for bot crawlers to update SEO metadata information to Google and other search engines.

I am using Nginx and PHP on server and its AngularJS on frontend. So PHP is executing via a reverse proxy mechanism to prepare meta information for the same page we are accessing via AngularJS in our main application.

The system is running like below

Main URL: https://www.angularapp.com/some-page
Proxy URL: https://www.phphtmlapp.com/some-page

Pseudo-code of proxy similar to

if (http_user_agent == 'facebookbot|googlebot') THEN
  proxy / https://www.phphtmlapp.com/

Is it a good approach or is there any better way to do this. Kindly suggest the better way.

  • 3
    Search engines dislike when they get provided a content that is different from the one provided to human visitors. If they detect the discrepancy this might reflect negatively on your website. – Patrick Mevzek Jun 22 '18 at 17:10
  • If you want good search engine rankings you just shouldn't use AngularJS. We get so many people here with problems. I'm not sure why such a poor framework for SEO is so popular. – Stephen Ostermiller Jun 22 '18 at 18:02
  • @PatrickMevzek Might reflect negatively? Huh! Try dropped like a hot potato! This is the fasted way to have a site delisted there is. Google uses other networks to compare results between what is being served to users and googlebot. If a difference is found, it is evaluated, tested over a short period on more than one page, then sites that are not within acceptable parameters, and it is small, are dropped completely immediately with a significant knock in it's trust score. Comming back from this is extremely slow. Cloaking, even for seemingly valid reasons, is always a bad idea. Cheers!! – closetnoc Jun 22 '18 at 20:08
  • Guys, unfortunately we have used angularjs now struggling with such SEO related issues, so we got all the problems mentioned by you and few other we got at our end.. Now what we can do to improve the SEO for this application – Vikas Chaudhary Jun 25 '18 at 13:28
  • What if the content returning by the proxy server is the exact replica of the content we are serving to the users, will it work? – Vikas Chaudhary Jun 25 '18 at 13:29

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.