Title: Disable auto-completion
Last modified: January 28, 2022

---

# Disable auto-completion

 *  Resolved [massdoo11](https://wordpress.org/support/users/massdoo11/)
 * (@massdoo11)
 * [4 years, 4 months ago](https://wordpress.org/support/topic/disable-auto-completion/)
 * Hello,
 * Is it possible to disable the auto-completion of the browser history in a form
   field?
 * Thanks You

Viewing 15 replies - 1 through 15 (of 17 total)

1 [2](https://wordpress.org/support/topic/disable-auto-completion/page/2/?output_format=md)
[→](https://wordpress.org/support/topic/disable-auto-completion/page/2/?output_format=md)

 *  Plugin Support [Imran – WPMU DEV Support](https://wordpress.org/support/users/wpmudev-support9/)
 * (@wpmudev-support9)
 * [4 years, 4 months ago](https://wordpress.org/support/topic/disable-auto-completion/#post-15303175)
 * Hello [@massdoo11](https://wordpress.org/support/users/massdoo11/) !
 * I trust you’re doing well!
 * Forminator doesn’t have a built-in option for that, but you can try the following
   script:
 *     ```
       <?php
   
       add_filter(
       	'forminator_render_form_markup',
       	function( $html, $fields ) {
       		return str_replace(
       			array( '<input', '<form' ),
       			array( '<input autocomplete="off"', '<form autocomplete="off"' ), 
       			$html 
       		);
       	},
       	10,
       	2
       );
       ```
   
 * To install the script, please copy the code to a .php file and place the file
   in wp-content/mu-plugins directory (please create the directory if it doesn’t
   exist).
 * This snippet will disable autocompletion on all Forminator forms, in all fields.
 * Best regards,
    Pawel
 *  Thread Starter [massdoo11](https://wordpress.org/support/users/massdoo11/)
 * (@massdoo11)
 * [4 years, 4 months ago](https://wordpress.org/support/topic/disable-auto-completion/#post-15309397)
 * Thank you for your message,
 * I just added the code in the folder
    But it doesn’t work :/
 * Image of code : [https://ibb.co/BGCNJ31](https://ibb.co/BGCNJ31)
 * Thanks
 *  Thread Starter [massdoo11](https://wordpress.org/support/users/massdoo11/)
 * (@massdoo11)
 * [4 years, 4 months ago](https://wordpress.org/support/topic/disable-auto-completion/#post-15309583)
 * I would like the auto-complete to be disabled mainly on an address field:
 * _<input autocomplete=”off” type=”text” name=”address-1-city” placeholder=”Par
   exemple : Paris, Lyon, Lille” id=”forminator-field-cityaddress-1″ class=”forminator-
   input pac-target-input” data-required=”1″ aria-required=”true” value=”” aria-
   invalid=”true”>_
 * However the auto-complete is well off
 *  Thread Starter [massdoo11](https://wordpress.org/support/users/massdoo11/)
 * (@massdoo11)
 * [4 years, 4 months ago](https://wordpress.org/support/topic/disable-auto-completion/#post-15309722)
 * UPDATE :
 * In the Chroome console, I changed “off” to “new-password” and it works. (screen
   [https://ibb.co/87pHjhf](https://ibb.co/87pHjhf))
 * So I modified the code :
 *     ```
       <?php
   
       add_filter(
       	'forminator_render_form_markup',
       	function( $html, $fields ) {
       		return str_replace(
       			array( '<input', '<form' ),
       			array( '<input autocomplete="new-password"', '<form autocomplete="new-password"' ), 
       			$html 
       		);
       	},
       	10,
       	2
       );
       ```
   
 * Off by new-password, but the field still remains in “auto-complete:off”
 * Thanks
 *  Plugin Support [Laura – WPMU DEV Support](https://wordpress.org/support/users/wpmudev-support8/)
 * (@wpmudev-support8)
 * [4 years, 4 months ago](https://wordpress.org/support/topic/disable-auto-completion/#post-15311474)
 * Hi [@massdoo11](https://wordpress.org/support/users/massdoo11/)
 * If you have modified the code but it remains the same on the page (in page source)
   then it means usually that cache is serving “old” version of the page.
 * Make sure that all the cache (on site/server/CDN if there is any) is cleared 
   and, just in case, you may also either clear browser cache or test in incognito
   browser tab after that. Purging all caches should get the change applied.
 * Kind regards
    Adam
 *  Thread Starter [massdoo11](https://wordpress.org/support/users/massdoo11/)
 * (@massdoo11)
 * [4 years, 4 months ago](https://wordpress.org/support/topic/disable-auto-completion/#post-15311525)
 * Thannks, The code doesn’t seem to work, it doesn’t disable autocompletion…
 *  Plugin Support [Laura – WPMU DEV Support](https://wordpress.org/support/users/wpmudev-support8/)
 * (@wpmudev-support8)
 * [4 years, 4 months ago](https://wordpress.org/support/topic/disable-auto-completion/#post-15311695)
 * Hi [@massdoo11](https://wordpress.org/support/users/massdoo11/)
 * I’m sorry but I’m a bit confused now:
 * – the original code that Pawel shared doesn’t work?
    – or your modification is
   still not applied (the one that apparently worked for you when added via Chrome
   browser)?
 * I’ve just tested Pawel’s code on my test site and it worked as expected there
   so either it’s still not applied correctly or there’s something in addition that’s
   breaking it.
 * I think you have tried to add that code using some sort of “php snippet” plugin,
   right?
 * Can you instead try to add it “manually”?:
 * – create an empty file with a .php extension (e.g. stop-autocomplete.php)
    – 
   copy and paste code that my colleague shared earlier – exactly as it is – into
   it – save the file – upload it to the “/wp-content/mu-plugin” folder of your 
   site via FTP, Cpanel “File Manager” or similar way
 * Once it’s there, again clear all cache on site/server and check if it works then,
   please.
 * Kind regards,
    Adam
 *  Thread Starter [massdoo11](https://wordpress.org/support/users/massdoo11/)
 * (@massdoo11)
 * [4 years, 4 months ago](https://wordpress.org/support/topic/disable-auto-completion/#post-15311732)
 * Pawel’s code.
 * I put the code in a .php file in the /wp-content/mu-plugins folder.
 * It appears well in my list of extensions, I also cleared my cache.
 * Do you have an email address so that I can send you the address of our form and
   more sensitive data?
 * thank you
 *  [Kris – WPMU DEV Support](https://wordpress.org/support/users/wpmudevsupport13/)
 * (@wpmudevsupport13)
 * [4 years, 4 months ago](https://wordpress.org/support/topic/disable-auto-completion/#post-15314779)
 * Hi [@massdoo11](https://wordpress.org/support/users/massdoo11/)
 * Could you export the form and share it in the next reply?
 * In order to export this form, you can go to the WordPress dashboard > Forminator
   Pro > Forms, and next to the Edit button you’ll find the Settings wheel. Click
   on it, and on the menu select Export. Once the Export Form window is opened, 
   you’ll see the Download button.
 * You can save the generated TXT file in Google Drive or Dropbox and then share
   with us the URLs so we may look into this.
    Also, share in Google Drive or Dropbox
   your PHP file which code. We will double-check on our side, does everything is
   ok.
 * Kind Regards,
    Kri
 *  Thread Starter [massdoo11](https://wordpress.org/support/users/massdoo11/)
 * (@massdoo11)
 * [4 years, 4 months ago](https://wordpress.org/support/topic/disable-auto-completion/#post-15315273)
 * Thank you for your help,
 * Here are the requested information
 * [https://www.dropbox.com/sh/nj7f9j30sho9h2r/AADB-QCJUI3M9MT1iGk0gyTna?dl=0](https://www.dropbox.com/sh/nj7f9j30sho9h2r/AADB-QCJUI3M9MT1iGk0gyTna?dl=0)
 * Kind Regards,
 *  Thread Starter [massdoo11](https://wordpress.org/support/users/massdoo11/)
 * (@massdoo11)
 * [4 years, 4 months ago](https://wordpress.org/support/topic/disable-auto-completion/#post-15325105)
 * Any news ?
 * Thanks 🙂
 *  Plugin Support [Nithin – WPMU DEV Support](https://wordpress.org/support/users/wpmudevsupport11/)
 * (@wpmudevsupport11)
 * [4 years, 4 months ago](https://wordpress.org/support/topic/disable-auto-completion/#post-15328837)
 * Hi [@massdoo11](https://wordpress.org/support/users/massdoo11/),
 * Thanks for sharing the form export. I tested the form in my test server with 
   the snippet that we initially shared in here:
    [https://wordpress.org/support/topic/disable-auto-completion/#post-15303175](https://wordpress.org/support/topic/disable-auto-completion/#post-15303175)
 * And can confirm it works out of the box in Chrome, Firefox. Are you able to replicate
   the issue on other browsers? or is it more specific to Chrome on your side?
 * Could we know the version of the browser you are testing on? Also, if possible
   please share a screenshot of what you notice on your side, so that it might help
   us give a better idea regarding the issue too.
 * Looking forward to your response.
 * Kind Regards,
    Nithin
 *  Thread Starter [massdoo11](https://wordpress.org/support/users/massdoo11/)
 * (@massdoo11)
 * [4 years, 4 months ago](https://wordpress.org/support/topic/disable-auto-completion/#post-15328878)
 * Hello,
 * It’s strange,
 * Chrome : Version 98.0.4758.82
    Here is the screen : [https://ibb.co/PQHtH95](https://ibb.co/PQHtH95)
 * Do you have an email address so that I can send you privately the address of 
   my site with the form ?
 * Thank you in advance
 *  Plugin Support [Patrick – WPMU DEV Support](https://wordpress.org/support/users/wpmudevsupport12/)
 * (@wpmudevsupport12)
 * [4 years, 4 months ago](https://wordpress.org/support/topic/disable-auto-completion/#post-15334370)
 * Hi [@massdoo11](https://wordpress.org/support/users/massdoo11/)
 * Would it be possible to send the Form link?
 * You can configure a temporary page.
 * Best Regards
    Patrick Freitas
 *  Thread Starter [massdoo11](https://wordpress.org/support/users/massdoo11/)
 * (@massdoo11)
 * [4 years, 4 months ago](https://wordpress.org/support/topic/disable-auto-completion/#post-15335757)
 * Hello,
 * Here is the link: [https://cutt.ly/oOJG1xD](https://cutt.ly/oOJG1xD)
 * Thank you

Viewing 15 replies - 1 through 15 (of 17 total)

1 [2](https://wordpress.org/support/topic/disable-auto-completion/page/2/?output_format=md)
[→](https://wordpress.org/support/topic/disable-auto-completion/page/2/?output_format=md)

The topic ‘Disable auto-completion’ is closed to new replies.

 * ![](https://ps.w.org/forminator/assets/icon-256x256.gif?rev=3443182)
 * [Forminator Forms – Contact Form, Payment Form & Custom Form Builder](https://wordpress.org/plugins/forminator/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/forminator/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/forminator/)
 * [Active Topics](https://wordpress.org/support/plugin/forminator/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/forminator/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/forminator/reviews/)

 * 17 replies
 * 7 participants
 * Last reply from: [Amin – WPMU DEV Support](https://wordpress.org/support/users/wpmudev-support2/)
 * Last activity: [4 years, 4 months ago](https://wordpress.org/support/topic/disable-auto-completion/page/2/#post-15359217)
 * Status: resolved