Cloud Flare Http to Https SSL Tracking Stopped Working

I just switch from http to https via Cloud Flare the website worked fine but now none of the sites in PIWIK are getting tracked.

is your piwik instance also reachable via https? Do you have https in the tracking code?
Otherwise it can’t work as HTTPS-pages can’t embed non-HTTPS resources.

Currently Piwik is http only.

I tried this

but as soon as I try the https - this error comes up Error code: SSL_ERROR_INTERNAL_ERROR_ALERT

RE: Do you have https in the tracking code? Under Website Management I have urls for both & https//


You’ll need to setup HTTPS on your piwik instance otherwise tracking isn’t possible. Browsers don’t allow embedding javascript from insecure sources in a HTTPS website as it would allow man-in-the-middle-attackers to circumvent the advantages of HTTPS.

I used cloudflare on the piwik domain, enabling https:// - now piwik is up and running after about a day of waiting. BUT when I go to the piwik dashboard it's not tracking anything - ALL zeros on ALL sites both https and http.


Can you visit your site and open your browsers developer tools can you see an error in the console?

If you open the network tab, can you check if the request to piwik.js and piwik.php don’t return an error.

Console > Errors (Same Errors under Net > All)

“NetworkError: 503 Service Unavailable -,2017-07-11&evolutionBy=nb_visits&columns=nb_visits&idSite=39&idsite=39&viewDataTable=sparkline&colors={“backgroundColor”%3A"%23ffffff"%2C"lineColor"%3A"%23162c4a"%2C"minPointColor"%3A"%23ff7f7f"%2C"maxPointColor"%3A"%2375bf7c"%2C"lastPointColor"%3A"%2355aaff"}
“NetworkError: 503 Service Unavailable -,2017-07-11&evolutionBy=nb_visits&columns=nb_visits&idSite=11&idsite=11&viewDataTable=sparkline&colors={“backgroundColor”%3A"%23ffffff"%2C"lineColor"%3A"%23162c4a"%2C"minPointColor"%3A"%23ff7f7f"%2C"maxPointColor"%3A"%2375bf7c"%2C"lastPointColor"%3A"%2355aaff"}
“NetworkError: 503 Service Unavailable -,2017-07-11&evolutionBy=nb_visits&columns=nb_visits&idSite=44&idsite=44&viewDataTable=sparkline&colors={“backgroundColor”%3A"%23ffffff"%2C"lineColor"%3A"%23162c4a"%2C"minPointColor"%3A"%23ff7f7f"%2C"maxPointColor"%3A"%2375bf7c"%2C"lastPointColor"%3A"%2355aaff"}
“NetworkError: 503 Service Unavailable -,2017-07-11&evolutionBy=nb_visits&columns=nb_visits&idSite=12&idsite=12&viewDataTable=sparkline&colors={“backgroundColor”%3A"%23ffffff"%2C"lineColor"%3A"%23162c4a"%2C"minPointColor"%3A"%23ff7f7f"%2C"maxPointColor"%3A"%2375bf7c"%2C"lastPointColor"%3A"%2355aaff"}

Under “Net” not seeing piwik.js or piwik.php

Found piwik.js via Firebug.

GET piwik.js abort 403 - https://https//

On working sites -

I would guess the https://https is causing the error but how to fix it?

Can’t really test it at the moment as i am not on my pc and doesn’t show a helpful site, but it seems like you are missing an : after https in your tracking code.

BTW: can’t test it more at the moment, but it seems like returns an invalid certificate.