Title: Google Analytics not showing hits after using Javascript for HTTPS
Last modified: August 30, 2016

---

# Google Analytics not showing hits after using Javascript for HTTPS

 *  Resolved [man1056](https://wordpress.org/support/users/man1056/)
 * (@man1056)
 * [10 years, 8 months ago](https://wordpress.org/support/topic/google-analytics-not-showing-hits-after-using-javascript-for-https/)
 * Hi there,
 * I use an Nginx server which doesn’t have htaccess enabled. On 26th I enabled 
   HTTPS redirection, which I think would be implemented through javascript.
 * From that day, Google analytics is showing zero organic search hits. It does 
   show Direct hits, referrals, etc. So it’s not that the GA code is not working.
   It’s as if the organic search results are not identified.
 * FYI, the Google webmaster does not show a decrease in number of clicks. In fact
   has increased, but the Analytics code does not show that.
 * Do you have any idea why this could be so?
 * Thanks.
 * [https://wordpress.org/plugins/really-simple-ssl/](https://wordpress.org/plugins/really-simple-ssl/)

Viewing 5 replies - 1 through 5 (of 5 total)

 *  Plugin Contributor [Rogier Lankhorst](https://wordpress.org/support/users/rogierlankhorst/)
 * (@rogierlankhorst)
 * [10 years, 8 months ago](https://wordpress.org/support/topic/google-analytics-not-showing-hits-after-using-javascript-for-https/#post-6602646)
 * If it is caused by the JavaScript redirect, it can be fixed by adding a redirect
   to nginx.
 * Did you try to change the domain in Google Analytics and search console to the
   https domain?
 *  Thread Starter [man1056](https://wordpress.org/support/users/man1056/)
 * (@man1056)
 * [10 years, 8 months ago](https://wordpress.org/support/topic/google-analytics-not-showing-hits-after-using-javascript-for-https/#post-6602679)
 * Hi RogierLankhorst,
 * Yes, I did change the URLs in GA and Webmaster to https.
 * I’m using this redirect rule in Nginx. Do you think this is the best way to do
   it?
 * `
    server { listen 80; server_name my-domain.com; return 301 https://$server_name
   $request_uri; }
 *  Plugin Contributor [Rogier Lankhorst](https://wordpress.org/support/users/rogierlankhorst/)
 * (@rogierlankhorst)
 * [10 years, 8 months ago](https://wordpress.org/support/topic/google-analytics-not-showing-hits-after-using-javascript-for-https/#post-6602691)
 * I I do not work with nginx, so I can’t tell you if the rule is good, but I think
   that would be the way to go.
 *  Thread Starter [man1056](https://wordpress.org/support/users/man1056/)
 * (@man1056)
 * [10 years, 8 months ago](https://wordpress.org/support/topic/google-analytics-not-showing-hits-after-using-javascript-for-https/#post-6602723)
 * OK. I’ve observed the site for a while now, and after the Nginx redirect rules
   are in place, organic hits are being registered in Google Analytics.
 * So, you might want to include this possibility in your docs and what to do about
   it.
 * Also, just want to say Thanks for making this great plugin. 🙂
 *  Plugin Contributor [Rogier Lankhorst](https://wordpress.org/support/users/rogierlankhorst/)
 * (@rogierlankhorst)
 * [10 years, 8 months ago](https://wordpress.org/support/topic/google-analytics-not-showing-hits-after-using-javascript-for-https/#post-6602745)
 * Thanks for the feedback, I will include it in the documentation.

Viewing 5 replies - 1 through 5 (of 5 total)

The topic ‘Google Analytics not showing hits after using Javascript for HTTPS’ is
closed to new replies.

 * ![](https://ps.w.org/really-simple-ssl/assets/icon-256x256.png?rev=2839720)
 * [Really Simple Security - Simple and Performant Security (formerly Really Simple SSL)](https://wordpress.org/plugins/really-simple-ssl/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/really-simple-ssl/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/really-simple-ssl/)
 * [Active Topics](https://wordpress.org/support/plugin/really-simple-ssl/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/really-simple-ssl/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/really-simple-ssl/reviews/)

 * 5 replies
 * 2 participants
 * Last reply from: [Rogier Lankhorst](https://wordpress.org/support/users/rogierlankhorst/)
 * Last activity: [10 years, 8 months ago](https://wordpress.org/support/topic/google-analytics-not-showing-hits-after-using-javascript-for-https/#post-6602745)
 * Status: resolved