Title: cf7 causing redirects
Last modified: February 4, 2017

---

# cf7 causing redirects

 *  [gordonrjones](https://wordpress.org/support/users/gordonrjones/)
 * (@gordonrjones)
 * [9 years, 4 months ago](https://wordpress.org/support/topic/cf7-causing-redirects/)
 * in doing a pagespeed test via [https://developers.google.com/speed/pagespeed/insights/](https://developers.google.com/speed/pagespeed/insights/)
   i see the following redirect error:
    [https://foo.com/?_wpcf7_is_ajax_call=1&_wpcf7=5&_wpcf7_request_ver=1486241732842](https://foo.com/?_wpcf7_is_ajax_call=1&_wpcf7=5&_wpcf7_request_ver=1486241732842)
 * the above uri redirects to our root http domain which then redirects to https.
   that’s two jumps i’d like to avoid. i’m not sure what’s going on with the initial
   contact form 7 parameter, why it’s appearing.
 * fwiw, we have a contact form hidden in a tab on our home page which i suspect
   is involved somehow
 * any thoughts? advice?

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

 *  [totallywp](https://wordpress.org/support/users/panatapattu/)
 * (@panatapattu)
 * [9 years, 4 months ago](https://wordpress.org/support/topic/cf7-causing-redirects/#post-8776375)
 * Hi,
 * Have you called wp_head() and wp_footer(), and they are in header.php and footer.
   php, respectively ?
 *  Thread Starter [gordonrjones](https://wordpress.org/support/users/gordonrjones/)
 * (@gordonrjones)
 * [9 years, 2 months ago](https://wordpress.org/support/topic/cf7-causing-redirects/#post-8976836)
 * thanks for the reply. the header and footer are both called.
 * after poking around this seems to be somewhat common issue with cf7 – but no 
   solution found.
 *  [SDDJ](https://wordpress.org/support/users/sddj/)
 * (@sddj)
 * [9 years ago](https://wordpress.org/support/topic/cf7-causing-redirects/#post-9122769)
 * Hey! I know this is a bit of a late reply here, but for future googlers and people
   like myself that are looking for a solution, this issue is caused by two things:
 * 1) The plugin doesn’t detect the http/s scheme of the site before doing the redirect,
   and
    2) because of the form using ajax submission.
 * To fix this, you have a few options. You can disable ajax submissions by adding
   the following to your functions.php file:
 * `define( 'WPCF7_LOAD_JS', false );`
 * or installing this plugin to disable it with a checkbox:
    [https://wordpress.org/plugins/contact-form-7-extras/](https://wordpress.org/plugins/contact-form-7-extras/)
 * or nicely and politely bug the author to check it out 🙂

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

The topic ‘cf7 causing redirects’ is closed to new replies.

 * ![](https://ps.w.org/contact-form-7/assets/icon.svg?rev=2339255)
 * [Contact Form 7](https://wordpress.org/plugins/contact-form-7/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/contact-form-7/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/contact-form-7/)
 * [Active Topics](https://wordpress.org/support/plugin/contact-form-7/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/contact-form-7/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/contact-form-7/reviews/)

## Tags

 * [redirect](https://wordpress.org/support/topic-tag/redirect/)

 * 3 replies
 * 2 participants
 * Last reply from: [gordonrjones](https://wordpress.org/support/users/gordonrjones/)
 * Last activity: [9 years ago](https://wordpress.org/support/topic/cf7-causing-redirects/#post-8976836)
 * Status: not resolved