Google Adsense Ads is the simple way to earn money just by displaying the targeted ads around your content. Here the ads targeting means ads related the content of your website or the users interest. Google approves Adsense ads only the selected websites i.e. which are approved by it.

Now we will tell you how to display google adsense ad Middle of WordPress posts ? There are two methods given below. The first way is by converting Google Adsense ad code into shortcode and the other way is using Plugin. So let us learn it.

Method-1: Add Google Adsense Ads Inside WordPress Posts without Plugin

Display Ads Middle of WordPress Post using Shortcode

If you want to insert 336*280 size ad in the mid of the post. You need to paste a long ad script inside the post. but if you are using wordpress then you should use wordpress shortcode. use only one simple step and you can convert long ad script into shortcode. Let us start how to convert long adsense ad code into wordpress shortcode. Step by Step we will go futher .

Step 1

First of all go to google adsense account and Login there with your email and password.

Google adsense

Step 2

When you successfully login in to your google adsense account then click on “My ads” link which is visible on top menu after login process.

Google Adsense My ads

Step 3

when you click on “My ads” then you will see “New ad unit” button.
click on “New ad unit” .

New ad Unit

Step 4

Choose or Select 336*280 ad size from Recommended Size.

Adsense Recommended Ad Size 336

and click on “Save and get code” button.

Save and get code

When you click on “Save and get code” button then you will see “Ad code” popup.

Select “Asynchronous” and Copy ad code script.

Asynchronous Adsense Ad Code

Step 5

Now to Go your WordPress Dashbord. Click on Appearance> Editor.

Wordpress appearance editor

when you click on “Editor” then Edit Themes (theme-editor.php) page will open. In theme editor page, look on right side links. click on “Theme functions(functions.php)” link.

Wordpress Theme editor

Step 6:- Convert Google Adsense Ad Code in to Shortcode.

open functions.php file and Create a function inside functions.php.

For Example function name is adsize_336.

function adsize_336() {
return '<script src="//" async=""></script>
<!-- wp post ad -->
<ins class="adsbygoogle" style="display: inline-block; width: 336px; height: 280px;" data-ad-client="ca-pub-XXXXXXXXXXXXXXXX" data-ad-slot="2087710448"></ins>
<script>// <![CDATA[
(adsbygoogle = window.adsbygoogle || []).push({});
// ]]></script>';


add_shortcode('adsense336', ' adsize_336');

Copy this code and paste in your functions.php. now replace your ad code script by the above given script. then Save functions.php.

Now your shortcode is [adsense336] . put this short code anywhere inside posts.

Method-2: Insert Adsense Ads Middle of WordPress Posts using Quick Adsense plugin

if you don’t want to use wp shortcode else you can use Quick Adsense WordPress plugin. click to Download Quick Adsense Plugin

The Advantage of using this plugin:

  • Display Ads Beginning of Post
  • Display Ads Middle of Post
  • Display Ads End of Post
  • Display Ads After Image
  • Display Ads Before the Last Paragraph
  • Display Ads End of Paragraph