{"id":1714,"date":"2020-06-17T15:50:04","date_gmt":"2020-06-17T13:50:04","guid":{"rendered":"https:\/\/www.wp-moon.com\/comment-se-debarrasser-de-publicites-qui-envahissent-mon-site-web\/"},"modified":"2020-06-18T11:06:39","modified_gmt":"2020-06-18T09:06:39","slug":"get-rid-of-ads-on-my-wordpress","status":"publish","type":"post","link":"https:\/\/www.wp-moon.com\/en\/get-rid-of-ads-on-my-wordpress\/","title":{"rendered":"How do I get rid of ads that invade my website?"},"content":{"rendered":"<div class=\"wpb-content-wrapper\"><p>[vc_row][vc_column][vc_custom_heading text=&#8221;Problem&#8221; use_theme_fonts=&#8221;yes&#8221;][\/vc_column][\/vc_row][vc_row][vc_column][vc_column_text]Until now your site was working very well, without any problems, but suddenly it started to display ads to your visitors. You do not have a contract with an advertising agency, you wanted to offer your visitors a site without advertising and therefore you did not request this type of display on your website.[\/vc_column_text][\/vc_column][\/vc_row][vc_row][vc_column][vc_custom_heading text=&#8221;The cause&#8221; use_theme_fonts=&#8221;yes&#8221;][vc_column_text]There are two main hypotheses that could explain these ads.<\/p>\n<p>The first is the installation of an <strong>infected theme or plugin<\/strong>. According on where you or your web developer gets their plugins and themes, a source may <strong>contain code that can cause advertisements<\/strong>\u00a0 on your website.<\/p>\n<p>An intrusion into your website, through a security flaw or a bad security setting of your site: several &#8220;gateways&#8221; exist to access a website if it is not sufficiently secured.[\/vc_column_text][\/vc_column][vc_column][vc_custom_heading text=&#8221;The solution&#8221; use_theme_fonts=&#8221;yes&#8221;][vc_column_text]The <strong>first case<\/strong>, the one where you or someone else has unintentionally introduced on your site an <strong>infected theme or plugin<\/strong>, the most efficient is to restore a previous<strong> full backup<\/strong> of your site. This will <strong>delete hacked files<\/strong>.<\/p>\n<p>If you don&#8217;t want to <strong>restore your site<\/strong>, or if you don&#8217;t have a <em>backup<\/em> (or one that is <em>too old<\/em>), there is also the possibility to &#8220;<em>clean<\/em>&#8221; your website: delete (with FTP(s)) the infected plugin or theme, identify database elements to be deleted&#8230; but be careful, <strong>we do not recommend this method<\/strong> (unless there is <em>no choice<\/em>): it is indeed difficult and time-consuming to make sure you have removed all traces of undesirable elements from your website. We recommend that you <a href=\"https:\/\/www.wp-moon.com\/contact-an-expert\/\" target=\"_blank\" rel=\"noopener noreferrer\">contact an expert<\/a> for this type of action who, in addition, can offer you an audit of your website to identify potential flaws.<\/p>\n<p>Reminder: it is important to fetch and download each element of your website from reliable, legal, controlled and recognized sources: the official website to download WordPress <a href=\"https:\/\/wordpress.org\/download\/\" target=\"_blank\" rel=\"noopener noreferrer\">https:\/\/wordpress.org\/download\/<\/a>, the official repositories of the themes <a href=\"https:\/\/wordpress.org\/themes\/\" target=\"_blank\" rel=\"noopener noreferrer\">https:\/\/wordpress.org\/themes\/<\/a> and the plugins <a href=\"https:\/\/wordpress.org\/plugins\/\" target=\"_blank\" rel=\"noopener noreferrer\">https:\/\/wordpress.org\/plugins\/<\/a>.<\/p>\n<p>In the <strong>second case<\/strong>, it is necessary to do the operation proposed in the first case: <strong>restoring your website<\/strong>, but above all and imperatively you will have to find the origin of the flaw that allowed these advertisements to set up.<\/p>\n<p>Here are a few steps to explore or secure :<\/p>\n<ul>\n<li>Have a <strong>secure hosting<\/strong>: if you decide to entrust your hosting to a provider, make sure that it is qualified to meet all the security constraints that a hosting must have. He will need to make sure that all measures have been taken and that the <strong>server is always up to date<\/strong>. The same applies to the database: <strong>accesses must be finely tuned<\/strong> so as not to risk unauthorized access with sometimes dramatic consequences (<em>data theft, destruction of the database<\/em>, etc.).<\/li>\n<li>Be <strong>up to date<\/strong> with WordPress: like your hosting, your WordPress installation must be up to date, as well as its different plugins and themes.<\/li>\n<li>Control access: limit the number of user accounts and <strong>grant only the necessary rights<\/strong>, check that your <strong>passwords<\/strong> are not too simple and<strong> change them<\/strong> if necessary.<\/li>\n<li>Have a strong backup strategy: <strong>several backups<\/strong> are recommended<\/li>\n<li>Check the<strong> origin of the elements<\/strong> on your site: you may have bookmarked the site on which you have downloaded a plugin or a theme&#8230; you could then find the origin of your problem. Feel free, if you can, to <strong>check the code<\/strong> or call on the <strong>WordPress forums for experts<\/strong> who can give you their opinion on a particular plugin or theme. Favour items that are well rated (with <em>real reviews<\/em>), downloaded many times and regularly updated.<\/li>\n<li>Analyze your computer: you can have all the necessary security on your website, if your <strong>computer<\/strong> is <strong>infected by a virus<\/strong>, you can give access to the administration of your website without even realizing it.<\/li>\n<li>For your <strong>hosting<\/strong>, make an inventory of <strong>activated services<\/strong> and their usefulness: do you use FTP instead of <strong>SFTP<\/strong>? Is it a good idea to log in to SSH?&#8230;<\/li>\n<li>Check the correct <strong>permissions setting for folders<\/strong> on your website: WordPress should be able to read and write to folders on your server, but it is <strong>dangerous<\/strong> to grant <strong>too many permissions<\/strong>. If you have a problem between WordPress and <em>read\/write<\/em> access to a folder, ask beforehand to give THE right permission, without opening it too wide or to everyone<\/li>\n<li>Secure sensitive WordPress files and folders: <em>wp-admin<\/em>, <em>wp-includes<\/em>, <em>wp-config.php<\/em>. Many tutorials exist to help you do this.<\/li>\n<li><strong>Increase the security<\/strong> of your WordPress: by <strong>denying the modification of files,<\/strong> by <strong>changing the access<\/strong> to the <strong>administration<\/strong> and by <strong>customizing the name of the administrator account<\/strong>, by installing a recognized security plugin to help you in these settings&#8230;<\/li>\n<li>Get an <strong>event logging<\/strong> strategy: in order to know what&#8217;s going on on your server or WordPress: unauthorized access, <em>who logged in<\/em>, <em>when<\/em>&#8230;<\/li>\n<li><strong>Regularly check the good health<\/strong> of your WordPress installation: server up to date? WordPress up to date? Plugin and theme up to date? No items added &#8220;<em>silently<\/em>&#8221; since the last check? Backups and integrity checks on them? Folders, files and database without unwanted items? Log analysis ? &#8230; it is advisable to make a <strong>complete checklist<\/strong> to be <strong>reused regularly<\/strong>.<\/li>\n<\/ul>\n<p>If you find a <strong>problem on any of these points<\/strong> above, you will need to take the appropriate steps to ensure that you do not run the risk of encountering problems again.[\/vc_column_text][\/vc_column][\/vc_row]<\/p>\n<\/div>","protected":false},"excerpt":{"rendered":"<p>Your WordPress starts displaying ads to your visitors and you don&#8217;t have this type of display installed. There are two hypotheses that could explain the appearance of these ads.<\/p>\n","protected":false},"author":2,"featured_media":1711,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[37],"tags":[140,57,130,142],"class_list":["post-1714","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-fix-errors","tag-audit-2","tag-hacking","tag-malware","tag-malware-fr-2"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v28.8 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>How do I get rid of ads that invade my website? - WP Moon<\/title>\n<meta name=\"description\" content=\"Your WordPress starts displaying ads to your visitors and you don&#039;t have this type of display installed. There are two hypotheses that could explain the appearance of these ads.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.wp-moon.com\/en\/get-rid-of-ads-on-my-wordpress\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"How do I get rid of ads that invade my website? - WP Moon\" \/>\n<meta property=\"og:description\" content=\"Your WordPress starts displaying ads to your visitors and you don&#039;t have this type of display installed. There are two hypotheses that could explain the appearance of these ads.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.wp-moon.com\/en\/get-rid-of-ads-on-my-wordpress\/\" \/>\n<meta property=\"og:site_name\" content=\"WP Moon\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/wpmoonwebsite\" \/>\n<meta property=\"article:published_time\" content=\"2020-06-17T13:50:04+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2020-06-18T09:06:39+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/www.wp-moon.com\/wp-content\/uploads\/2020\/06\/comment-se-debarrasser-de-publicites-qui-envahissent-mon-site-web.png\" \/>\n\t<meta property=\"og:image:width\" content=\"870\" \/>\n\t<meta property=\"og:image:height\" content=\"493\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/png\" \/>\n<meta name=\"author\" content=\"Alexandre G\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@alexgaboriau\" \/>\n<meta name=\"twitter:site\" content=\"@WPMoon4\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Alexandre G\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"5 minutes\" \/>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"How do I get rid of ads that invade my website? - WP Moon","description":"Your WordPress starts displaying ads to your visitors and you don't have this type of display installed. There are two hypotheses that could explain the appearance of these ads.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.wp-moon.com\/en\/get-rid-of-ads-on-my-wordpress\/","og_locale":"en_US","og_type":"article","og_title":"How do I get rid of ads that invade my website? - WP Moon","og_description":"Your WordPress starts displaying ads to your visitors and you don't have this type of display installed. There are two hypotheses that could explain the appearance of these ads.","og_url":"https:\/\/www.wp-moon.com\/en\/get-rid-of-ads-on-my-wordpress\/","og_site_name":"WP Moon","article_publisher":"https:\/\/www.facebook.com\/wpmoonwebsite","article_published_time":"2020-06-17T13:50:04+00:00","article_modified_time":"2020-06-18T09:06:39+00:00","og_image":[{"width":870,"height":493,"url":"https:\/\/www.wp-moon.com\/wp-content\/uploads\/2020\/06\/comment-se-debarrasser-de-publicites-qui-envahissent-mon-site-web.png","type":"image\/png"}],"author":"Alexandre G","twitter_card":"summary_large_image","twitter_creator":"@alexgaboriau","twitter_site":"@WPMoon4","twitter_misc":{"Written by":"Alexandre G","Est. reading time":"5 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.wp-moon.com\/en\/get-rid-of-ads-on-my-wordpress\/#article","isPartOf":{"@id":"https:\/\/www.wp-moon.com\/en\/get-rid-of-ads-on-my-wordpress\/"},"author":{"name":"Alexandre G","@id":"https:\/\/www.wp-moon.com\/en\/#\/schema\/person\/72a64e6910977ec9e4b32fd8da54369d"},"headline":"How do I get rid of ads that invade my website?","datePublished":"2020-06-17T13:50:04+00:00","dateModified":"2020-06-18T09:06:39+00:00","mainEntityOfPage":{"@id":"https:\/\/www.wp-moon.com\/en\/get-rid-of-ads-on-my-wordpress\/"},"wordCount":977,"commentCount":0,"publisher":{"@id":"https:\/\/www.wp-moon.com\/en\/#organization"},"image":{"@id":"https:\/\/www.wp-moon.com\/en\/get-rid-of-ads-on-my-wordpress\/#primaryimage"},"thumbnailUrl":"https:\/\/www.wp-moon.com\/wp-content\/uploads\/2020\/06\/comment-se-debarrasser-de-publicites-qui-envahissent-mon-site-web.png","keywords":["audit","hacking","malware","malware"],"articleSection":["Fix Errors"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/www.wp-moon.com\/en\/get-rid-of-ads-on-my-wordpress\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/www.wp-moon.com\/en\/get-rid-of-ads-on-my-wordpress\/","url":"https:\/\/www.wp-moon.com\/en\/get-rid-of-ads-on-my-wordpress\/","name":"How do I get rid of ads that invade my website? - WP Moon","isPartOf":{"@id":"https:\/\/www.wp-moon.com\/en\/#website"},"primaryImageOfPage":{"@id":"https:\/\/www.wp-moon.com\/en\/get-rid-of-ads-on-my-wordpress\/#primaryimage"},"image":{"@id":"https:\/\/www.wp-moon.com\/en\/get-rid-of-ads-on-my-wordpress\/#primaryimage"},"thumbnailUrl":"https:\/\/www.wp-moon.com\/wp-content\/uploads\/2020\/06\/comment-se-debarrasser-de-publicites-qui-envahissent-mon-site-web.png","datePublished":"2020-06-17T13:50:04+00:00","dateModified":"2020-06-18T09:06:39+00:00","description":"Your WordPress starts displaying ads to your visitors and you don't have this type of display installed. There are two hypotheses that could explain the appearance of these ads.","breadcrumb":{"@id":"https:\/\/www.wp-moon.com\/en\/get-rid-of-ads-on-my-wordpress\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.wp-moon.com\/en\/get-rid-of-ads-on-my-wordpress\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.wp-moon.com\/en\/get-rid-of-ads-on-my-wordpress\/#primaryimage","url":"https:\/\/www.wp-moon.com\/wp-content\/uploads\/2020\/06\/comment-se-debarrasser-de-publicites-qui-envahissent-mon-site-web.png","contentUrl":"https:\/\/www.wp-moon.com\/wp-content\/uploads\/2020\/06\/comment-se-debarrasser-de-publicites-qui-envahissent-mon-site-web.png","width":870,"height":493},{"@type":"BreadcrumbList","@id":"https:\/\/www.wp-moon.com\/en\/get-rid-of-ads-on-my-wordpress\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.wp-moon.com\/en\/"},{"@type":"ListItem","position":2,"name":"Fix Errors","item":"https:\/\/www.wp-moon.com\/en\/category\/fix-errors\/"},{"@type":"ListItem","position":3,"name":"How do I get rid of ads that invade my website?"}]},{"@type":"WebSite","@id":"https:\/\/www.wp-moon.com\/en\/#website","url":"https:\/\/www.wp-moon.com\/en\/","name":"WP Moon","description":"","publisher":{"@id":"https:\/\/www.wp-moon.com\/en\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.wp-moon.com\/en\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/www.wp-moon.com\/en\/#organization","name":"WP Moon","url":"https:\/\/www.wp-moon.com\/en\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.wp-moon.com\/en\/#\/schema\/logo\/image\/","url":"https:\/\/www.wp-moon.com\/wp-content\/uploads\/2020\/02\/logo.png","contentUrl":"https:\/\/www.wp-moon.com\/wp-content\/uploads\/2020\/02\/logo.png","width":290,"height":95,"caption":"WP Moon"},"image":{"@id":"https:\/\/www.wp-moon.com\/en\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/www.facebook.com\/wpmoonwebsite","https:\/\/x.com\/WPMoon4"]},{"@type":"Person","@id":"https:\/\/www.wp-moon.com\/en\/#\/schema\/person\/72a64e6910977ec9e4b32fd8da54369d","name":"Alexandre G","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.wp-moon.com\/wp-content\/uploads\/2023\/09\/312419460_10229483707296045_2919774527885824513_n-100x100.jpg","url":"https:\/\/www.wp-moon.com\/wp-content\/uploads\/2023\/09\/312419460_10229483707296045_2919774527885824513_n-100x100.jpg","contentUrl":"https:\/\/www.wp-moon.com\/wp-content\/uploads\/2023\/09\/312419460_10229483707296045_2919774527885824513_n-100x100.jpg","caption":"Alexandre G"},"description":"Alexandre, Web Developer &amp; Website Editor. I've been using WordPress for over 10 years in my professional environment and on personal projects. I created WP Moon to teach you how to use this CMS, solve your problems and show you all the tricks.","sameAs":["https:\/\/www.croque-pixel.com\/","https:\/\/x.com\/alexgaboriau","https:\/\/www.youtube.com\/@wp_moon\/videos"],"url":"https:\/\/www.wp-moon.com\/en\/author\/wp-moon\/"}]}},"_links":{"self":[{"href":"https:\/\/www.wp-moon.com\/en\/wp-json\/wp\/v2\/posts\/1714","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.wp-moon.com\/en\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.wp-moon.com\/en\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.wp-moon.com\/en\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.wp-moon.com\/en\/wp-json\/wp\/v2\/comments?post=1714"}],"version-history":[{"count":0,"href":"https:\/\/www.wp-moon.com\/en\/wp-json\/wp\/v2\/posts\/1714\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.wp-moon.com\/en\/wp-json\/wp\/v2\/media\/1711"}],"wp:attachment":[{"href":"https:\/\/www.wp-moon.com\/en\/wp-json\/wp\/v2\/media?parent=1714"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.wp-moon.com\/en\/wp-json\/wp\/v2\/categories?post=1714"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.wp-moon.com\/en\/wp-json\/wp\/v2\/tags?post=1714"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}